From: Wouter Wijngaards Date: Wed, 20 Jan 2010 13:11:11 +0000 (+0000) Subject: fixup lookup trouble for parent-child domains on the first query. X-Git-Tag: release-1.4.2~51 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2bd83fd0cf8a819cec4f2fed39c0e70321c345ee;p=thirdparty%2Funbound.git fixup lookup trouble for parent-child domains on the first query. git-svn-id: file:///svn/unbound/trunk@1960 be551aaa-1e26-0410-a405-d3ace91eadb9 --- diff --git a/iterator/iterator.c b/iterator/iterator.c index f454e18f2..43621bd8a 100644 --- a/iterator/iterator.c +++ b/iterator/iterator.c @@ -195,6 +195,12 @@ error_supers(struct module_qstate* qstate, int id, struct module_qstate* super) delegpt_log(VERB_ALGO, super_iq->dp); log_assert(0); return; + } else { + /* see if the failure did get (parent-lame) info */ + if(!cache_fill_missing(super->env, + super_iq->qchase.qclass, super->region, + super_iq->dp)) + log_err("out of memory adding missing"); } dpns->resolved = 1; /* mark as failed */ super_iq->num_target_queries--; diff --git a/services/cache/dns.c b/services/cache/dns.c index 2651767e3..25ca76813 100644 --- a/services/cache/dns.c +++ b/services/cache/dns.c @@ -248,8 +248,6 @@ cache_fill_missing(struct module_env* env, uint16_t qclass, struct ub_packed_rrset_key* akey; uint32_t now = *env->now; for(ns = dp->nslist; ns; ns = ns->next) { - if(ns->resolved) - continue; akey = rrset_cache_lookup(env->rrset_cache, ns->name, ns->namelen, LDNS_RR_TYPE_A, qclass, 0, now, 0); if(akey) {