From 560577af00220070e4d327b0ae22c3377773fa2e Mon Sep 17 00:00:00 2001 From: Frank Denis Date: Tue, 22 Oct 2019 11:53:59 +0200 Subject: [PATCH] Correctly honor MaxTimeout on Windows, too --- dnscrypt-proxy/netprobe_windows.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dnscrypt-proxy/netprobe_windows.go b/dnscrypt-proxy/netprobe_windows.go index e36ae593..79274f38 100644 --- a/dnscrypt-proxy/netprobe_windows.go +++ b/dnscrypt-proxy/netprobe_windows.go @@ -19,7 +19,7 @@ func NetProbe(address string, timeout int) error { if timeout < 0 { timeout = MaxTimeout } else { - timeout = Max(MaxTimeout, timeout) + timeout = Min(MaxTimeout, timeout) } for tries := timeout; tries > 0; tries-- { pc, err := net.DialUDP("udp", nil, remoteUDPAddr)