]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
adjust timeout to allow for ECN negotiation failures
authorMark Andrews <marka@isc.org>
Fri, 28 Dec 2018 04:16:04 +0000 (15:16 +1100)
committerEvan Hunt <each@isc.org>
Wed, 16 Jan 2019 01:10:41 +0000 (17:10 -0800)
lib/dns/resolver.c

index 7b09edf20719107ab51af69b438233b831f367eb..da9083010e530800e890f2fde459d2b08554ba3b 100644 (file)
@@ -1919,6 +1919,15 @@ fctx_query(fetchctx_t *fctx, dns_adbaddrinfo_t *addrinfo,
 
        srtt = addrinfo->srtt;
 
+       /*
+        * Allow an additional second for the kernel to resend the SYN (or
+        * SYN without ECN in the case of stupid firewalls blocking ECN
+        * negotiation) over the current RTT estimate.
+        */
+       if ((options & DNS_FETCHOPT_TCP) != 0) {
+               srtt += 1000000;
+       }
+
        /*
         * A forwarder needs to make multiple queries. Give it at least
         * a second to do these in.