]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
on connect error, send the actual result to the caller
authorEvan Hunt <each@isc.org>
Tue, 31 Jan 2023 21:30:12 +0000 (13:30 -0800)
committerEvan Hunt <each@isc.org>
Tue, 28 Mar 2023 19:39:05 +0000 (12:39 -0700)
formerly if a connection failed in dns_request, the callback
function was called with ISC_R_CANCELED. change this to the
actual result code so the failure is correctly reported.

lib/dns/request.c

index e3bef774b5738579584e0cff44a2a2d52469fd0e..f78a57d7a32df1461bca899c680e802e064bf2fa 100644 (file)
@@ -921,7 +921,7 @@ req_connected(isc_result_t eresult, isc_region_t *region, void *arg) {
                req_send(request);
        } else {
                request_cancel(request);
-               req_sendevent(request, ISC_R_CANCELED);
+               req_sendevent(request, eresult);
        }
        UNLOCK(&request->requestmgr->locks[request->hash]);