From 9a44a5c920d048a6d701cabcb66c35eeb3dac34a Mon Sep 17 00:00:00 2001 From: yon2004 Date: Sat, 28 Apr 2018 15:43:35 +1000 Subject: [PATCH] HTTP timeout set to wrong value. Because the defaultTimeout is defined as a constant you do not need to multiply it by time.Second again otherwise you end up with some stupid timeout as seen here. https://play.golang.org/p/Dl7rU_n_8Ej --- tunneldns/https_upstream.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tunneldns/https_upstream.go b/tunneldns/https_upstream.go index 1c681dfc..03d7520c 100644 --- a/tunneldns/https_upstream.go +++ b/tunneldns/https_upstream.go @@ -43,7 +43,7 @@ func NewUpstreamHTTPS(endpoint string) (Upstream, error) { http2.ConfigureTransport(transport) client := &http.Client{ - Timeout: time.Second * defaultTimeout, + Timeout: defaultTimeout, Transport: transport, }