From: Jeremy Harris Date: Sun, 7 May 2017 15:55:12 +0000 (+0100) Subject: Testsuite: fix fakens to not claim that an unsupported NXDOMAIN is dnssec-AD X-Git-Url: https://git.exim.org/users/jgh/exim.git/commitdiff_plain/e48f2b5b162c82ed8be7ea8fd85e562a5c5de11b Testsuite: fix fakens to not claim that an unsupported NXDOMAIN is dnssec-AD --- diff --git a/test/src/fakens.c b/test/src/fakens.c index 0806136cc..34f5ea670 100644 --- a/test/src/fakens.c +++ b/test/src/fakens.c @@ -342,9 +342,6 @@ if (typeptr->name == NULL) rrdomain[0] = 0; /* No previous domain */ (void)fseek(f, 0, SEEK_SET); /* Start again at the beginning */ -if (dnssec) *dnssec = TRUE; /* cancelled by first nonsecure rec found */ -if (aa) *aa = TRUE; /* cancelled by first non-aa rec found */ - /* Scan for RRs */ while (fgets(CS buffer, sizeof(buffer), f) != NULL) @@ -438,7 +435,12 @@ while (fgets(CS buffer, sizeof(buffer), f) != NULL) /* The domain matches */ - if (yield == HOST_NOT_FOUND) yield = NO_DATA; + if (yield == HOST_NOT_FOUND) + { + yield = NO_DATA; + if (dnssec) *dnssec = TRUE; /* cancelled by first nonsecure rec found */ + if (aa) *aa = TRUE; /* cancelled by first non-aa rec found */ + } /* Compare RR types; a CNAME record is always returned */