fix a use-after-free in resolver
when processing a mismatched response, we call dns_dispatch_getnext(). If that fails, for example because of a timeout, fctx_done() is called, which cancels all queries. This triggers a crash afterward when fctx_cancelquery() is called, and is unnecessary since fctx_done() would have been called later anyway.
This commit is contained in:
@@ -9344,10 +9344,6 @@ rctx_next(respctx_t *rctx) {
|
||||
INSIST(rctx->query->dispentry != NULL);
|
||||
dns_message_reset(rctx->query->rmessage, DNS_MESSAGE_INTENTPARSE);
|
||||
result = dns_dispatch_getnext(rctx->query->dispentry);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
fctx_done(rctx->fctx, result, __LINE__);
|
||||
}
|
||||
|
||||
return (result);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user