summaryrefslogtreecommitdiffstats
path: root/freebsd/lib/libc/net/gethostnamadr.c
diff options
context:
space:
mode:
Diffstat (limited to 'freebsd/lib/libc/net/gethostnamadr.c')
-rw-r--r--freebsd/lib/libc/net/gethostnamadr.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/freebsd/lib/libc/net/gethostnamadr.c b/freebsd/lib/libc/net/gethostnamadr.c
index 5c158467..7960be7c 100644
--- a/freebsd/lib/libc/net/gethostnamadr.c
+++ b/freebsd/lib/libc/net/gethostnamadr.c
@@ -458,23 +458,19 @@ fakeaddr(const char *name, int af, struct hostent *hp, char *buf,
}
strncpy(hed->hostbuf, name, MAXDNAME);
hed->hostbuf[MAXDNAME] = '\0';
-#ifdef INET6
if (af == AF_INET && (statp->options & RES_USE_INET6) != 0U) {
_map_v4v6_address((char *)hed->host_addr,
(char *)hed->host_addr);
af = AF_INET6;
}
-#endif
he.h_addrtype = af;
switch(af) {
case AF_INET:
he.h_length = NS_INADDRSZ;
break;
-#ifdef INET6
case AF_INET6:
he.h_length = NS_IN6ADDRSZ;
break;
-#endif
default:
errno = EAFNOSUPPORT;
RES_SET_H_ERRNO(statp, NETDB_INTERNAL);