diff options
author | hrs <hrs@FreeBSD.org> | 2011-06-06 03:37:33 +0000 |
---|---|---|
committer | hrs <hrs@FreeBSD.org> | 2011-06-06 03:37:33 +0000 |
commit | 9c9abb47360b4acc3f7c54ac33eef70f41c40e87 (patch) | |
tree | 2f2a37b401cca2b4ce3e05841e3313cadcc91034 /etc | |
parent | 10df0af5a54c03a258caf94e9931b16eec080d79 (diff) | |
download | FreeBSD-src-9c9abb47360b4acc3f7c54ac33eef70f41c40e87.zip FreeBSD-src-9c9abb47360b4acc3f7c54ac33eef70f41c40e87.tar.gz |
Remove "ifconfig IF inet6 -accept_rtadv" when ipv6_gateway_enable=YES because
this is no longer needed.
Diffstat (limited to 'etc')
-rw-r--r-- | etc/network.subr | 26 |
1 files changed, 10 insertions, 16 deletions
diff --git a/etc/network.subr b/etc/network.subr index 64fb0fe..a5bdd67 100644 --- a/etc/network.subr +++ b/etc/network.subr @@ -100,25 +100,19 @@ ifconfig_up() # inet6 specific if afexists inet6; then - if ipv6if $1; then - if checkyesno ipv6_gateway_enable; then - _ipv6_opts="-accept_rtadv" - fi + if checkyesno ipv6_activate_all_interfaces; then + _ipv6_opts="-ifdisabled" else - if checkyesno ipv6_activate_all_interfaces; then - _ipv6_opts="-ifdisabled" - else - _ipv6_opts="ifdisabled" - fi - - # backward compatibility: $ipv6_enable - case $ipv6_enable in - [Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1) - _ipv6_opts="${_ipv6_opts} accept_rtadv" - ;; - esac + _ipv6_opts="ifdisabled" fi + # backward compatibility: $ipv6_enable + case $ipv6_enable in + [Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1) + _ipv6_opts="${_ipv6_opts} accept_rtadv" + ;; + esac + if [ -n "${_ipv6_opts}" ]; then ifconfig $1 inet6 ${_ipv6_opts} fi |