aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHiroki Sato <hrs@FreeBSD.org>2012-10-27 20:17:59 +0000
committerHiroki Sato <hrs@FreeBSD.org>2012-10-27 20:17:59 +0000
commit181544fef6529384a5cf53b826f7218e2d89e67d (patch)
tree928799f9fb6ba8c6261b7be331d8f59d9c83a661
parent451a0efc67693b173b694335081a2c20a40219ac (diff)
downloadsrc-181544fef6529384a5cf53b826f7218e2d89e67d.tar.gz
src-181544fef6529384a5cf53b826f7218e2d89e67d.zip
MFC of r242187:
Fix an issue when ipv6_enable=YES && ipv6_gateway_enable=YES which could prevent rtadvd(8) from working as intended. Approved by: re (kib)
Notes
Notes: svn path=/releng/9.1/; revision=242189
-rw-r--r--etc/network.subr10
1 files changed, 8 insertions, 2 deletions
diff --git a/etc/network.subr b/etc/network.subr
index 070f88497cbf..b2e8cb86f7a6 100644
--- a/etc/network.subr
+++ b/etc/network.subr
@@ -109,7 +109,9 @@ ifconfig_up()
# backward compatibility: $ipv6_enable
case $ipv6_enable in
[Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1)
- _ipv6_opts="${_ipv6_opts} accept_rtadv"
+ if ! checkyesno ipv6_gateway_enable; then
+ _ipv6_opts="${_ipv6_opts} accept_rtadv"
+ fi
;;
esac
@@ -488,7 +490,11 @@ ipv6_autoconfif()
# backward compatibility: $ipv6_enable
case $ipv6_enable in
[Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1)
- return 0
+ if checkyesno ipv6_gateway_enable; then
+ return 1
+ else
+ return 0
+ fi
;;
esac