From: Brad Fitzpatrick Date: Thu, 23 Jul 2015 00:45:32 +0000 (-0700) Subject: net: make GODEBUG=netdns=cgo force cgo as documented X-Git-Tag: go1.5beta3~102 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=17befdcec01fcd9c629c2cebf3aab5d4b6d70dc7;p=gostls13.git net: make GODEBUG=netdns=cgo force cgo as documented It wasn't working. The wrong variable was used. This would ideally have tests. It's also DEBUG. Fixes #11816 Change-Id: Iec42d229b81d78cece4ba5c73f3040e2356eb98f Reviewed-on: https://go-review.googlesource.com/12544 Run-TryBot: Brad Fitzpatrick Reviewed-by: Ian Lance Taylor TryBot-Result: Gobot Gobot --- diff --git a/src/net/conf.go b/src/net/conf.go index e70178d34c..01bb585ce6 100644 --- a/src/net/conf.go +++ b/src/net/conf.go @@ -80,7 +80,7 @@ func initConfVal() { _, localDomainDefined := syscall.Getenv("LOCALDOMAIN") if os.Getenv("RES_OPTIONS") != "" || os.Getenv("HOSTALIASES") != "" || - netCgo || + confVal.netCgo || localDomainDefined { confVal.forceCgoLookupHost = true return