diff options
author | nectar <nectar@FreeBSD.org> | 2002-02-04 19:12:46 +0000 |
---|---|---|
committer | nectar <nectar@FreeBSD.org> | 2002-02-04 19:12:46 +0000 |
commit | ebeabb1ba32f14e308ae9aff9a2a7151265259cf (patch) | |
tree | 71ba64d0a82be4894e23f6d65f36b61203ec3875 /contrib/bind/lib/inet/inet_ntop.c | |
parent | 1385a0dca8f9199ece158336f4c6a9f1e2e03c3e (diff) | |
download | FreeBSD-src-ebeabb1ba32f14e308ae9aff9a2a7151265259cf.zip FreeBSD-src-ebeabb1ba32f14e308ae9aff9a2a7151265259cf.tar.gz |
Import of ISC BIND 8.3.1-REL.
Diffstat (limited to 'contrib/bind/lib/inet/inet_ntop.c')
-rw-r--r-- | contrib/bind/lib/inet/inet_ntop.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/contrib/bind/lib/inet/inet_ntop.c b/contrib/bind/lib/inet/inet_ntop.c index d588e9f..e05812e 100644 --- a/contrib/bind/lib/inet/inet_ntop.c +++ b/contrib/bind/lib/inet/inet_ntop.c @@ -16,7 +16,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static const char rcsid[] = "$Id: inet_ntop.c,v 1.10 2001/01/25 20:21:10 vixie Exp $"; +static const char rcsid[] = "$Id: inet_ntop.c,v 1.11 2001/09/27 15:12:57 marka Exp $"; #endif /* LIBC_SCCS and not lint */ #include "port_before.h" @@ -175,8 +175,9 @@ inet_ntop6(src, dst, size) if (i != 0) *tp++ = ':'; /* Is this address an encapsulated IPv4? */ - if (i == 6 && best.base == 0 && - (best.len == 6 || (best.len == 5 && words[5] == 0xffff))) { + if (i == 6 && best.base == 0 && (best.len == 6 || + (best.len == 7 && words[7] != 0x0001) || + (best.len == 5 && words[5] == 0xffff))) { if (!inet_ntop4(src+12, tp, sizeof tmp - (tp - tmp))) return (NULL); tp += strlen(tp); |