summaryrefslogtreecommitdiff
path: root/lib/libc
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2006-11-17 01:11:24 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2006-11-17 01:11:24 +0000
commitd47bdeb6300d8da6e915c6e5f97a3d3d6b7e4b5d (patch)
treea7a1d754c5bbab5286abc8c4377cf6af4a694d4e /lib/libc
parentf90ac2555337c72651bc65977807ddf57df6db9a (diff)
change semantics of ff01::/16 to interface local multicast
(to sync up with more recent IPv6 spec) ok from: deraadt mcbride
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/getaddrinfo.c5
-rw-r--r--lib/libc/net/getnameinfo.c6
2 files changed, 6 insertions, 5 deletions
diff --git a/lib/libc/net/getaddrinfo.c b/lib/libc/net/getaddrinfo.c
index 06ab8f2095d..46a44e517c0 100644
--- a/lib/libc/net/getaddrinfo.c
+++ b/lib/libc/net/getaddrinfo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: getaddrinfo.c,v 1.56 2006/04/18 02:57:10 ray Exp $ */
+/* $OpenBSD: getaddrinfo.c,v 1.57 2006/11/17 01:11:23 itojun Exp $ */
/* $KAME: getaddrinfo.c,v 1.31 2000/08/31 17:36:43 itojun Exp $ */
/*
@@ -933,7 +933,8 @@ ip6_str2scopeid(char *scope, struct sockaddr_in6 *sin6, u_int32_t *scopeid)
if (*scope == '\0')
return -1;
- if (IN6_IS_ADDR_LINKLOCAL(a6) || IN6_IS_ADDR_MC_LINKLOCAL(a6)) {
+ if (IN6_IS_ADDR_LINKLOCAL(a6) || IN6_IS_ADDR_MC_LINKLOCAL(a6) ||
+ IN6_IS_ADDR_MC_INTFACELOCAL(a6)) {
/*
* We currently assume a one-to-one mapping between links
* and interfaces, so we simply use interface indices for
diff --git a/lib/libc/net/getnameinfo.c b/lib/libc/net/getnameinfo.c
index 4c8ee80fecd..57e0ddf3bea 100644
--- a/lib/libc/net/getnameinfo.c
+++ b/lib/libc/net/getnameinfo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: getnameinfo.c,v 1.31 2005/06/19 04:44:34 marcm Exp $ */
+/* $OpenBSD: getnameinfo.c,v 1.32 2006/11/17 01:11:23 itojun Exp $ */
/* $KAME: getnameinfo.c,v 1.45 2000/09/25 22:43:56 itojun Exp $ */
/*
@@ -335,8 +335,8 @@ ip6_sa2str(const struct sockaddr_in6 *sa6, char *buf, size_t bufsiz, int flags)
#endif
/* if_indextoname() does not take buffer size. not a good api... */
- if ((IN6_IS_ADDR_LINKLOCAL(a6) || IN6_IS_ADDR_MC_LINKLOCAL(a6)) &&
- bufsiz >= IF_NAMESIZE) {
+ if ((IN6_IS_ADDR_LINKLOCAL(a6) || IN6_IS_ADDR_MC_LINKLOCAL(a6) ||
+ IN6_IS_ADDR_MC_INTFACELOCAL(a6)) && bufsiz >= IF_NAMESIZE) {
char *p = if_indextoname(ifindex, buf);
if (p) {
return(strlen(p));