Commit 2408a4bb authored by Russ Cox's avatar Russ Cox

net: allow _ in names

Enables lookup of _jabber._tcp.gmail.com's SRV record.

Fixes #1167.

R=r, r2
CC=golang-dev
https://golang.org/cl/2353043
parent 7eb13b95
...@@ -207,7 +207,7 @@ func isDomainName(s string) bool { ...@@ -207,7 +207,7 @@ func isDomainName(s string) bool {
switch { switch {
default: default:
return false return false
case 'a' <= c && c <= 'z' || 'A' <= c && c <= 'Z': case 'a' <= c && c <= 'z' || 'A' <= c && c <= 'Z' || c == '_':
ok = true ok = true
case '0' <= c && c <= '9': case '0' <= c && c <= '9':
// fine // fine
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment