mirror of https://github.com/golang/go.git
net: do not call time.Now() twice
LGTM=bradfitz R=golang-codereviews, bradfitz CC=golang-codereviews https://golang.org/cl/104080043
This commit is contained in:
parent
d131ffefad
commit
f837078c50
|
|
@ -51,7 +51,7 @@ func readHosts() {
|
|||
}
|
||||
}
|
||||
// Update the data cache.
|
||||
hosts.expire = time.Now().Add(cacheMaxAge)
|
||||
hosts.expire = now.Add(cacheMaxAge)
|
||||
hosts.path = hp
|
||||
hosts.byName = hs
|
||||
hosts.byAddr = is
|
||||
|
|
|
|||
Loading…
Reference in New Issue