ipn/ipnlocal: fix Content-Length in DoH DNS proxy response

Updates #1713

Change-Id: I912d90383b751ad97b32bcec55e8fedbcf4d3db8
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
Brad Fitzpatrick 2021-11-30 14:18:48 -08:00 committed by Brad Fitzpatrick
parent 2a95ee4680
commit 16abd7e07c
1 changed files with 1 additions and 1 deletions

View File

@ -849,7 +849,7 @@ func (h *peerAPIHandler) handleDNSQuery(w http.ResponseWriter, r *http.Request)
return
}
w.Header().Set("Content-Type", "application/dns-message")
w.Header().Set("Content-Length", strconv.Itoa(len(q)))
w.Header().Set("Content-Length", strconv.Itoa(len(res)))
w.Write(res)
}