2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-30 22:15:20 +00:00

cache_name() sometimes returned DNS_R_UNCHANGED instead of DNS_R_SUCCESS,

causing some queries to secure domains to return SERVFAIL
This commit is contained in:
Andreas Gustafsson
2000-04-20 17:56:03 +00:00
parent de7787e364
commit ad4e4fe2a3

View File

@@ -2356,16 +2356,18 @@ cache_name(fetchctx_t *fctx, dns_name_t *name, isc_stdtime_t now) {
result = dns_db_addrdataset(res->view->cachedb,
node, NULL, now,
rdataset, 0, NULL);
if (result != ISC_R_SUCCESS &&
result != DNS_R_UNCHANGED)
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
if (result != ISC_R_SUCCESS)
break;
if (sigrdataset != NULL) {
result = dns_db_addrdataset(res->view->cachedb,
node, NULL, now,
sigrdataset, 0,
NULL);
if (result != ISC_R_SUCCESS &&
result != DNS_R_UNCHANGED)
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
if (result != ISC_R_SUCCESS)
break;
}
if (ANSWER(rdataset)) {