Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
net: LookupAddr adds trailing dots to entries from /etc/hosts #13564
Here is a program:
When run, it prints:
This is incorrect, given this /etc/hosts:
Names obtained from the DNS system are rooted and have a trailing dot. Names obtained from /etc/hosts should not.
This is a partial regression from Go 1.5 and should be fixed for Go 1.6.
It looks like Go 1.5 was inconsistent based on what routines were being used:
and now netdns=go has been changed to match netdns=cgo:
I'm not sure that's the right fix.