summaryrefslogtreecommitdiff
path: root/sys/netinet6
diff options
context:
space:
mode:
Diffstat (limited to 'sys/netinet6')
-rw-r--r--sys/netinet6/in6_ifattach.c14
-rw-r--r--sys/netinet6/nd6_rtr.c7
2 files changed, 2 insertions, 19 deletions
diff --git a/sys/netinet6/in6_ifattach.c b/sys/netinet6/in6_ifattach.c
index 032484b7691..4c7dc3cf6c0 100644
--- a/sys/netinet6/in6_ifattach.c
+++ b/sys/netinet6/in6_ifattach.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: in6_ifattach.c,v 1.90 2015/07/18 15:05:32 mpi Exp $ */
+/* $OpenBSD: in6_ifattach.c,v 1.91 2015/08/17 10:57:24 mpi Exp $ */
/* $KAME: in6_ifattach.c,v 1.124 2001/07/18 08:32:51 jinmei Exp $ */
/*
@@ -300,13 +300,7 @@ in6_ifattach_linklocal(struct ifnet *ifp, struct in6_addr *ifid)
* configure link-local address.
*/
bzero(&ifra, sizeof(ifra));
-
- /*
- * in6_update_ifa() does not use ifra_name, but we accurately set it
- * for safety.
- */
strncpy(ifra.ifra_name, ifp->if_xname, sizeof(ifra.ifra_name));
-
ifra.ifra_addr.sin6_family = AF_INET6;
ifra.ifra_addr.sin6_len = sizeof(struct sockaddr_in6);
ifra.ifra_addr.sin6_addr.s6_addr16[0] = htons(0xfe80);
@@ -408,13 +402,7 @@ in6_ifattach_loopback(struct ifnet *ifp)
KASSERT(ifp->if_flags & IFF_LOOPBACK);
bzero(&ifra, sizeof(ifra));
-
- /*
- * in6_update_ifa() does not use ifra_name, but we accurately set it
- * for safety.
- */
strncpy(ifra.ifra_name, ifp->if_xname, sizeof(ifra.ifra_name));
-
ifra.ifra_prefixmask.sin6_len = sizeof(struct sockaddr_in6);
ifra.ifra_prefixmask.sin6_family = AF_INET6;
ifra.ifra_prefixmask.sin6_addr = in6mask128;
diff --git a/sys/netinet6/nd6_rtr.c b/sys/netinet6/nd6_rtr.c
index fa2ab04e923..0323d71de82 100644
--- a/sys/netinet6/nd6_rtr.c
+++ b/sys/netinet6/nd6_rtr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nd6_rtr.c,v 1.113 2015/07/18 15:51:17 mpi Exp $ */
+/* $OpenBSD: nd6_rtr.c,v 1.114 2015/08/17 10:57:24 mpi Exp $ */
/* $KAME: nd6_rtr.c,v 1.97 2001/02/07 11:09:13 itojun Exp $ */
/*
@@ -2043,12 +2043,7 @@ in6_ifadd(struct nd_prefix *pr, int privacy)
}
/* make ifaddr */
-
bzero(&ifra, sizeof(ifra));
- /*
- * in6_update_ifa() does not use ifra_name, but we accurately set it
- * for safety.
- */
strncpy(ifra.ifra_name, ifp->if_xname, sizeof(ifra.ifra_name));
ifra.ifra_addr.sin6_family = AF_INET6;
ifra.ifra_addr.sin6_len = sizeof(struct sockaddr_in6);