* SOFTWARE.
*/
-/* $Id: resolver.c,v 1.137.2.7 2000/07/27 21:39:42 gson Exp $ */
+/* $Id: resolver.c,v 1.137.2.8 2000/07/27 21:42:14 gson Exp $ */
#include <config.h>
} else if (!ANSWER(rdataset))
continue;
- if (ANSWER(rdataset)) {
+ if (ANSWER(rdataset) && need_validation) {
if (fctx->type != dns_rdatatype_any &&
fctx->type != dns_rdatatype_sig) {
/*
if (secure_domain) {
/*
- * Do negative response validation.
+ * Mark all rdatasets as pending.
*/
- dns_validator_t *validator;
- isc_task_t *task;
dns_rdataset_t *trdataset;
dns_name_t *tname;
if (result != ISC_R_NOMORE)
return (result);
- validator = NULL;
- task = res->buckets[fctx->bucketnum].task;
+ }
+
+ if (need_validation) {
+ /*
+ * Do negative response validation.
+ */
+ dns_validator_t *validator = NULL;
+ isc_task_t *task = res->buckets[fctx->bucketnum].task;
+
result = dns_validator_create(res->view, name, fctx->type,
NULL, NULL,
fctx->rmessage, 0, task,
* to process the message, letting the validation complete
* in its own good time.
*/
- if (need_validation)
- return (ISC_R_SUCCESS);
+ return (ISC_R_SUCCESS);
}
LOCK(&res->buckets[fctx->bucketnum].lock);