commit | 7c77e450ccbf1459b4628f3564aeb0a0482b08f1 | [log] [tgz] |
---|---|---|
author | Russ Cox <rsc@golang.org> | Wed Apr 28 19:36:04 2010 -0700 |
committer | Russ Cox <rsc@golang.org> | Wed Apr 28 19:36:04 2010 -0700 |
tree | 63735487244217f72f9543324bfa3660776347b7 | |
parent | 0485ba72c3810b9ab52209318c5dfa490c97f7e2 [diff] [blame] |
net: do not require newline at end of resolv.conf Fixes #686. R=adg CC=golang-dev https://golang.org/cl/961046
diff --git a/src/pkg/net/parse.go b/src/pkg/net/parse.go index a7dcb35..ff980f4 100644 --- a/src/pkg/net/parse.go +++ b/src/pkg/net/parse.go
@@ -35,6 +35,11 @@ return } } + if len(f.data) > 0 { + s = string(data) + f.data = nil + ok = true + } return }