summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-01-17 15:58:12 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-01-17 15:58:12 +0000
commitcfdd8cb5501ff84b4fbf3c166ddb87e555de6b1b (patch)
tree5c74e1b845b8f8918ce22508b624e69921665ffd /lib
parent4b0fd6fa10ef9895285bd4e88a0b6e1057fc0af2 (diff)
do not filter address families that are not supported by kernel.
it was not a correct behavior. even if we may be able to connect to the the returned addresses, filtering them out is not a correct thing to do. for example, even if you have partial unreachablility in IPv4, gethostbyname(3) will return IPv4 addresses in the unreachable network anyways.
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/net/getaddrinfo.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/libc/net/getaddrinfo.c b/lib/libc/net/getaddrinfo.c
index 3fa1ce01d48..d4cd76b30c0 100644
--- a/lib/libc/net/getaddrinfo.c
+++ b/lib/libc/net/getaddrinfo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: getaddrinfo.c,v 1.6 2000/01/17 08:15:26 itojun Exp $ */
+/* $OpenBSD: getaddrinfo.c,v 1.7 2000/01/17 15:58:11 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -440,7 +440,9 @@ explore_fqdn(pai, hostname, servname, res)
const char *servname;
struct addrinfo **res;
{
+#if 0
int s;
+#endif
struct hostent *hp;
int h_error;
int af;
@@ -458,6 +460,7 @@ explore_fqdn(pai, hostname, servname, res)
sentinel.ai_next = NULL;
cur = &sentinel;
+#if 0
/*
* filter out AFs that are not supported by the kernel
* XXX errno?
@@ -468,6 +471,7 @@ explore_fqdn(pai, hostname, servname, res)
return 0;
} else
close(s);
+#endif
/*
* if the servname does not match socktype/protocol, ignore it.