From 434ef46661ca1e8bfc89e720313f22d998c65b8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Witold=20Kr=C4=99cicki?= Date: Tue, 23 Apr 2019 13:50:02 +0200 Subject: [PATCH] When resuming from qname-minimization increase fetches-per-zone counters for the 'new' zone (cherry picked from commit 7043c6eaf5676d6e7ba146d3a02633546c2c7310) --- CHANGES | 3 +++ lib/dns/resolver.c | 7 +++++++ 2 files changed, 10 insertions(+) diff --git a/CHANGES b/CHANGES index 20e9185167..a295722d10 100644 --- a/CHANGES +++ b/CHANGES @@ -2,6 +2,9 @@ 5217. [bug] Restore key id calculation for RSAMD5. [GL #996] +5216. [bug] Fetches-per-zone counter wasn't updated correctly + when doing qname minimization. [GL #992] + 5215. [bug] Change #5124 was incomplete; named could still return FORMERR instead of SERVFAIL in some cases. [GL #990] diff --git a/lib/dns/resolver.c b/lib/dns/resolver.c index 3241edb75f..99676882df 100644 --- a/lib/dns/resolver.c +++ b/lib/dns/resolver.c @@ -4192,6 +4192,13 @@ resume_qmin(isc_task_t *task, isc_event_t *event) { fctx_done(fctx, result, __LINE__); goto cleanup; } + + result = fcount_incr(fctx, false); + if (result != ISC_R_SUCCESS) { + fctx_done(fctx, result, __LINE__); + goto cleanup; + } + dns_name_free(&fctx->qmindcname, fctx->mctx); dns_name_init(&fctx->qmindcname, NULL); result = dns_name_dup(dcname, fctx->mctx, &fctx->qmindcname);