cmd/derper: fix regression from bootstrap DNS optimization
The commit b9c92b90db
earlier today
caused a regression of serving an empty map always, as it was
JSON marshalling an atomic.Value instead of the DNS entries map
it just built.
Change-Id: I9da3eeca132c6324462dedeaa7d002908557384b
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
parent
84046d6f7c
commit
a80cef0c13
|
@ -47,7 +47,7 @@ func refreshBootstrapDNS() {
|
||||||
}
|
}
|
||||||
dnsEntries[name] = addrs
|
dnsEntries[name] = addrs
|
||||||
}
|
}
|
||||||
j, err := json.MarshalIndent(dnsCache, "", "\t")
|
j, err := json.MarshalIndent(dnsEntries, "", "\t")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
// leave the old values in place
|
// leave the old values in place
|
||||||
return
|
return
|
||||||
|
|
Loading…
Reference in New Issue