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>
pull/3918/head
Brad Fitzpatrick 2 years ago committed by Brad Fitzpatrick
parent 84046d6f7c
commit a80cef0c13

@ -47,7 +47,7 @@ func refreshBootstrapDNS() {
}
dnsEntries[name] = addrs
}
j, err := json.MarshalIndent(dnsCache, "", "\t")
j, err := json.MarshalIndent(dnsEntries, "", "\t")
if err != nil {
// leave the old values in place
return

Loading…
Cancel
Save