mirror of
https://github.com/isc-projects/bind9.git
synced 2026-07-16 12:15:25 -04:00
In rctx_answer return DNS_R_DELEGATION on NOFOLLOW
When DNS_FETCHOPT_NOFOLLOW is set DNS_R_DELEGATION needs to be returned to restart the resolution process rather than converting it to ISC_R_SUCCESS.
This commit is contained in:
parent
80bc0ee075
commit
ea11650376
1 changed files with 11 additions and 2 deletions
|
|
@ -7615,7 +7615,8 @@ resquery_response(isc_result_t eresult, isc_region_t *region, void *arg) {
|
|||
break;
|
||||
case DNS_R_DELEGATION:
|
||||
/*
|
||||
* With NOFOLLOW we want to pass the result code.
|
||||
* With NOFOLLOW we want to pass return
|
||||
* DNS_R_DELEGATION to resume_qmin.
|
||||
*/
|
||||
if ((fctx->options & DNS_FETCHOPT_NOFOLLOW) == 0) {
|
||||
result = ISC_R_SUCCESS;
|
||||
|
|
@ -8156,6 +8157,14 @@ rctx_answer(respctx_t *rctx) {
|
|||
}
|
||||
|
||||
if (result == DNS_R_DELEGATION) {
|
||||
/*
|
||||
* With NOFOLLOW we want to return DNS_R_DELEGATION to
|
||||
* resume_qmin.
|
||||
*/
|
||||
if ((rctx->fctx->options & DNS_FETCHOPT_NOFOLLOW) != 0)
|
||||
{
|
||||
return (result);
|
||||
}
|
||||
result = ISC_R_SUCCESS;
|
||||
} else {
|
||||
/*
|
||||
|
|
@ -8197,7 +8206,7 @@ rctx_answer_positive(respctx_t *rctx) {
|
|||
isc_result_t result;
|
||||
fetchctx_t *fctx = rctx->fctx;
|
||||
|
||||
FCTXTRACE("rctx_answer");
|
||||
FCTXTRACE("rctx_answer_positive");
|
||||
|
||||
rctx_answer_init(rctx);
|
||||
rctx_answer_scan(rctx);
|
||||
|
|
|
|||
Loading…
Reference in a new issue