<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">Apply by doing:
        cd /usr/src
        patch -p0 &lt; 021_bind.patch

Then rebuild and install bind:
        cd usr.sbin/bind
        make -f Makefile.bsd-wrapper obj
        make -f Makefile.bsd-wrapper
        make -f Makefile.bsd-wrapper install

Index: usr.sbin/bind/lib/dns/resolver.c
===================================================================
RCS file: /cvs/src/usr.sbin/bind/lib/dns/resolver.c,v
retrieving revision 1.5
retrieving revision 1.5.2.1
diff -u -p -r1.5 -r1.5.2.1
--- usr.sbin/bind/lib/dns/resolver.c	18 Nov 2003 14:14:06 -0000	1.5
+++ usr.sbin/bind/lib/dns/resolver.c	5 Nov 2004 01:04:58 -0000	1.5.2.1
@@ -473,7 +473,7 @@ fctx_cancelquery(resquery_t **queryp, dn
 			 */
 			INSIST(no_response);
 			rtt = query-&gt;addrinfo-&gt;srtt +
-				(100000 * fctx-&gt;restarts);
+				(200000 * fctx-&gt;restarts);
 			if (rtt &gt; 10000000)
 				rtt = 10000000;
 			/*
@@ -685,7 +685,10 @@ resquery_senddone(isc_task_t *task, isc_
 				isc_socket_detach(&amp;query-&gt;tcpsocket);
 			resquery_destroy(&amp;query);
 		}
-	} else if (sevent-&gt;result != ISC_R_SUCCESS)
+	} else if (sevent-&gt;result == ISC_R_HOSTUNREACH ||
+		   sevent-&gt;result == ISC_R_NETUNREACH)
+		fctx_cancelquery(&amp;query, NULL, NULL, ISC_TRUE);
+	else if (sevent-&gt;result != ISC_R_SUCCESS)
 		fctx_cancelquery(&amp;query, NULL, NULL, ISC_FALSE);
 
 	isc_event_free(&amp;event);
@@ -1266,6 +1269,10 @@ resquery_connected(isc_task_t *task, isc
 						 ISC_FALSE);
 				fctx_done(fctx, result);
 			}
+		} else if (sevent-&gt;result == ISC_R_HOSTUNREACH ||
+			   sevent-&gt;result == ISC_R_NETUNREACH) {
+			isc_socket_detach(&amp;query-&gt;tcpsocket);
+			fctx_cancelquery(&amp;query, NULL, NULL, ISC_TRUE);
 		} else {
 			isc_socket_detach(&amp;query-&gt;tcpsocket);
 			fctx_cancelquery(&amp;query, NULL, NULL, ISC_FALSE);
</pre></body></html>