]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
fixup lookup trouble for parent-child domains on the first query.
authorWouter Wijngaards <wouter@nlnetlabs.nl>
Wed, 20 Jan 2010 13:11:11 +0000 (13:11 +0000)
committerWouter Wijngaards <wouter@nlnetlabs.nl>
Wed, 20 Jan 2010 13:11:11 +0000 (13:11 +0000)
git-svn-id: file:///svn/unbound/trunk@1960 be551aaa-1e26-0410-a405-d3ace91eadb9

iterator/iterator.c
services/cache/dns.c

index f454e18f249c521cf291ae5a57e67fe5578d0a9d..43621bd8a1d381d650a1ee143bb2749067f59940 100644 (file)
@@ -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--; 
index 2651767e35869ed3c5c0016aeb7c3ceacd477413..25ca768132611aa7d307946a5a529a9e7077d00b 100644 (file)
@@ -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) {