summaryrefslogtreecommitdiff
path: root/src/net/hosts_test.go
diff options
context:
space:
mode:
authorBurcu Dogan <jbd@google.com>2015-10-01 15:01:50 -0400
committerBurcu Dogan <jbd@google.com>2015-10-01 20:52:54 +0000
commitd96a3a2d113909a470d2fd039018e1852a8d72b8 (patch)
tree1693ee062148772f1122c83a09e12c6608d95922 /src/net/hosts_test.go
parentf1b25c4ccfdd72745407f846e55399b194a23c90 (diff)
downloadgo-git-d96a3a2d113909a470d2fd039018e1852a8d72b8.tar.gz
net: make /etc/hosts lookups case-insensitive
The native Go host resolver was behaving differently than libc and the entries in the /etc/hosts were handled in a case sensitive way. In order to be compatible with libc's resolver, /etc/hosts lookups must be case-insensitive. Fixes #12806. Change-Id: I3c14001abffadf7458fd1a027c91e6438a87f285 Reviewed-on: https://go-review.googlesource.com/15321 Run-TryBot: Burcu Dogan <jbd@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src/net/hosts_test.go')
-rw-r--r--src/net/hosts_test.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/net/hosts_test.go b/src/net/hosts_test.go
index aca64c38b0..99569cd016 100644
--- a/src/net/hosts_test.go
+++ b/src/net/hosts_test.go
@@ -74,6 +74,7 @@ var lookupStaticAddrTests = []struct {
{"255.255.255.255", []string{"broadcasthost"}},
{"127.0.0.2", []string{"odin"}},
{"127.0.0.3", []string{"odin"}},
+ {"127.0.0.4", []string{"bor"}},
{"::2", []string{"odin"}},
{"127.1.1.1", []string{"thor"}},
{"127.1.1.2", []string{"ullr", "ullrhost"}},