]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Don't hide errors in librdns
authorAndrew Lewis <nerf@judo.za.org>
Tue, 27 Sep 2016 11:51:11 +0000 (13:51 +0200)
committerAndrew Lewis <nerf@judo.za.org>
Tue, 27 Sep 2016 13:28:33 +0000 (15:28 +0200)
contrib/librdns/resolver.c

index 8c5df913f05da8b5ba0b882f06abd5f1c1bd5835..d6ddea5769860e9edf62555f53a1f2aaa2ccbdba 100644 (file)
@@ -230,7 +230,9 @@ rdns_parse_reply (uint8_t *in, int r, struct rdns_request *req,
 
        if (!found && type != RDNS_REQUEST_ANY) {
                /* We have not found the requested RR type */
-               rep->code = RDNS_RC_NOREC;
+               if (rep->code == RDNS_RC_NOERROR) {
+                       rep->code = RDNS_RC_NOREC;
+               }
        }
 
        *_rep = rep;