diff --git a/lib/dns/request.c b/lib/dns/request.c index 8f53d37812..b2b7b119b9 100644 --- a/lib/dns/request.c +++ b/lib/dns/request.c @@ -1061,7 +1061,9 @@ req_response(isc_result_t result, isc_region_t *region, void *arg) { if (result == ISC_R_TIMEDOUT) { LOCK(&request->requestmgr->locks[request->hash]); - if (request->udpcount > 1) { + if (request->udpcount > 1 && + (request->flags & DNS_REQUEST_F_TCP) == 0) + { request->udpcount -= 1; dns_dispatch_resume(request->dispentry, request->timeout);