Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/net visit all requests even if we get errors from n...
details: https://anonhg.NetBSD.org/src/rev/138d9024c91f
branches: trunk
changeset: 483706:138d9024c91f
user: itojun <itojun%NetBSD.org@localhost>
date: Thu Mar 16 13:51:43 2000 +0000
description:
visit all requests even if we get errors from name server.
this will solve name query failures for IPv4-only node, when
the DNS server returns SERVFAIL or NXDOMAIN (should success with an == 0).
PR: 9621
diffstat:
lib/libc/net/getaddrinfo.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diffs (28 lines):
diff -r f076b4ab0736 -r 138d9024c91f lib/libc/net/getaddrinfo.c
--- a/lib/libc/net/getaddrinfo.c Thu Mar 16 12:40:51 2000 +0000
+++ b/lib/libc/net/getaddrinfo.c Thu Mar 16 13:51:43 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: getaddrinfo.c,v 1.34 2000/02/22 05:47:15 itojun Exp $ */
+/* $NetBSD: getaddrinfo.c,v 1.35 2000/03/16 13:51:43 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -1610,6 +1610,7 @@
return (n);
}
n = res_send(buf, n, answer, anslen);
+#if 0
if (n < 0) {
#ifdef DEBUG
if (_res.options & RES_DEBUG)
@@ -1618,8 +1619,9 @@
h_errno = TRY_AGAIN;
return (n);
}
+#endif
- if (hp->rcode != NOERROR || ntohs(hp->ancount) == 0) {
+ if (n < 0 || hp->rcode != NOERROR || ntohs(hp->ancount) == 0) {
rcode = hp->rcode; /* record most recent error */
#ifdef DEBUG
if (_res.options & RES_DEBUG)
Home |
Main Index |
Thread Index |
Old Index