]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
fixup error handling in libunbound ub_resolve().
authorWouter Wijngaards <wouter@nlnetlabs.nl>
Tue, 15 Jul 2008 10:22:39 +0000 (10:22 +0000)
committerWouter Wijngaards <wouter@nlnetlabs.nl>
Tue, 15 Jul 2008 10:22:39 +0000 (10:22 +0000)
git-svn-id: file:///svn/unbound/trunk@1149 be551aaa-1e26-0410-a405-d3ace91eadb9

doc/Changelog
libunbound/libunbound.c

index 07147ddbfbe19f046420f8ee028b82d19e5eceee..82b14794e395e1dda1348388717694f7e49ce57c 100644 (file)
@@ -2,6 +2,7 @@
        - Follow draft-ietf-dnsop-default-local-zones-06 added reverse
          IPv6 example prefix to AS112 default blocklist.
        - fixup lookup of DS records by client with trustanchor for same.
+       - libunbound ub_resolve, fix handling of error condition during setup.
 
 3 July 2008: Wouter
        - Matthijs fixed memory leaks in root hints file reading.
index 4b7a6d5e3a9f1fb4c68e2fa130f52a41a259dcbf..901e87033c53560c5680d69ef0071e8eeb249ffd 100644 (file)
@@ -576,6 +576,7 @@ ub_resolve(struct ub_ctx* ctx, char* name, int rrtype,
 {
        struct ctx_query* q;
        int r;
+       *result = NULL;
 
        lock_basic_lock(&ctx->cfglock);
        if(!ctx->finalized) {
@@ -591,7 +592,6 @@ ub_resolve(struct ub_ctx* ctx, char* name, int rrtype,
        if(!q)
                return UB_NOMEM;
        /* become a resolver thread for a bit */
-       *result = NULL;
 
        r = libworker_fg(ctx, q);
        if(r) {