summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-10-18 18:49:40 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-10-18 18:49:40 +0000
commita40d2c06d976207f6f22bf2fdb7f5e6f6a1c3822 (patch)
tree24f3dd621fdd465943b69e38063c05eac1aabc42 /sys
parentfd7edcab55f4546c61340e5e34ea568c6a1d0e79 (diff)
don't try to configure IPv6 on bridge*. comment from deraadt
Diffstat (limited to 'sys')
-rw-r--r--sys/netinet6/in6_ifattach.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/sys/netinet6/in6_ifattach.c b/sys/netinet6/in6_ifattach.c
index 6df70e57750..5f5bffc8e5f 100644
--- a/sys/netinet6/in6_ifattach.c
+++ b/sys/netinet6/in6_ifattach.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: in6_ifattach.c,v 1.11 2000/10/02 04:45:03 itojun Exp $ */
-/* $KAME: in6_ifattach.c,v 1.67 2000/10/01 10:51:54 itojun Exp $ */
+/* $OpenBSD: in6_ifattach.c,v 1.12 2000/10/18 18:49:39 itojun Exp $ */
+/* $KAME: in6_ifattach.c,v 1.68 2000/10/18 18:44:24 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -586,6 +586,18 @@ in6_ifattach(ifp, altifp)
struct in6_ifaddr *ia;
struct in6_addr in6;
+ /* some of the interfaces are inherently not IPv6 capable */
+ switch (ifp->if_type) {
+ case IFT_BRIDGE:
+ return;
+ case IFT_PROPVIRTUAL:
+ if (strncmp("bridge", ifp->if_xname, sizeof("bridge")) == 0 &&
+ '0' <= ifp->if_xname[sizeof("bridge")] &&
+ ifp->if_xname[sizeof("bridge")] <= '9')
+ return;
+ break;
+ }
+
/*
* We have some arrays that should be indexed by if_index.
* since if_index will grow dynamically, they should grow too.