Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > media > main-src > by-pkgid > a0ef309aba3a78d3350b149f382e72aa > files > 74

bind-9.3.6-25.P1.el5_11.12.src.rpm

diff -up bind-9.3.6-P1/bin/dig/dighost.c.rh726120 bind-9.3.6-P1/bin/dig/dighost.c
--- bind-9.3.6-P1/bin/dig/dighost.c.rh726120	2011-10-28 14:53:21.259778359 +0200
+++ bind-9.3.6-P1/bin/dig/dighost.c	2011-10-28 14:54:45.679265676 +0200
@@ -2213,8 +2213,13 @@ connect_timeout(isc_task_t *task, isc_ev
 		}
 	} else {
 		fputs(l->cmdline, stdout);
-		printf(";; connection timed out; no servers could be "
-		       "reached\n");
+		if (!next_origin(NULL, query)) {
+			printf(";; connection timed out; no servers could be "
+			       "reached\n");
+		} else {
+			printf(";; connection timed out; trying next "
+			       "origin\n");
+		}
 		cancel_lookup(l);
 		check_next_lookup(l);
 		if (exitcode < 9)
@@ -2835,7 +2840,8 @@ recv_done(isc_task_t *task, isc_event_t 
 		return;
 	}
 	if ((msg->rcode == dns_rcode_servfail && !l->servfail_stops) ||
-	    (check_ra && (msg->flags & DNS_MESSAGEFLAG_RA) == 0 && l->recurse))
+	    (check_ra && (msg->flags & DNS_MESSAGEFLAG_RA) == 0 &&
+	     msg->rcode != dns_rcode_noerror && l->recurse))
 	{
 		dig_query_t *next = ISC_LIST_NEXT(query, link);
 		if (l->current_query == query)