Apply by doing:
        cd /usr/src
        patch -p0 < 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->addrinfo->srtt +
-				(100000 * fctx->restarts);
+				(200000 * fctx->restarts);
 			if (rtt > 10000000)
 				rtt = 10000000;
 			/*
@@ -685,7 +685,10 @@ resquery_senddone(isc_task_t *task, isc_
 				isc_socket_detach(&query->tcpsocket);
 			resquery_destroy(&query);
 		}
-	} else if (sevent->result != ISC_R_SUCCESS)
+	} else if (sevent->result == ISC_R_HOSTUNREACH ||
+		   sevent->result == ISC_R_NETUNREACH)
+		fctx_cancelquery(&query, NULL, NULL, ISC_TRUE);
+	else if (sevent->result != ISC_R_SUCCESS)
 		fctx_cancelquery(&query, NULL, NULL, ISC_FALSE);
 
 	isc_event_free(&event);
@@ -1266,6 +1269,10 @@ resquery_connected(isc_task_t *task, isc
 						 ISC_FALSE);
 				fctx_done(fctx, result);
 			}
+		} else if (sevent->result == ISC_R_HOSTUNREACH ||
+			   sevent->result == ISC_R_NETUNREACH) {
+			isc_socket_detach(&query->tcpsocket);
+			fctx_cancelquery(&query, NULL, NULL, ISC_TRUE);
 		} else {
 			isc_socket_detach(&query->tcpsocket);
 			fctx_cancelquery(&query, NULL, NULL, ISC_FALSE);
