diff options
author | Roy Marples <roy@marples.name> | 2007-08-03 13:53:20 +0000 |
---|---|---|
committer | Roy Marples <roy@marples.name> | 2007-08-03 13:53:20 +0000 |
commit | 65a9e4618baadff217dd36216b5c64f2ad66dfc6 (patch) | |
tree | 073e7e99893f971d972ecb22ac328dba309c3563 | |
parent | a3aff5d83cc3cbe2db1515e4a9ae7c7bd66d55c6 (diff) |
Fix static IPv6 routes, #187514.
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | net.Linux/ifconfig.sh | 17 | ||||
-rw-r--r-- | net.Linux/iproute2.sh | 2 |
3 files changed, 18 insertions, 5 deletions
@@ -1,6 +1,10 @@ # ChangeLog for Gentoo System Intialization ("rc") scripts # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPLv2 + 03 Aug 2007; Roy Marples <uberlord@gentoo.org>: + + Fix static IPv6 routes, #187514. + * baselayout-2.0.0_rc1 (02 Aug 2007) 01 Aug 2007; Mike Frysinger <vapier@gentoo.org>: diff --git a/net.Linux/ifconfig.sh b/net.Linux/ifconfig.sh index e30ff8eb..7192ca8a 100644 --- a/net.Linux/ifconfig.sh +++ b/net.Linux/ifconfig.sh @@ -161,6 +161,12 @@ _add_address() { } _add_route() { + local inet6= + + if [ -n "${metric}" ] ; then + set -- "$@" metric ${metric} + fi + if [ $# -eq 3 ] ; then set -- "$1" "$2" gw "$3" elif [ "$3" = "via" ] ; then @@ -169,11 +175,14 @@ _add_route() { set -- "${one}" "${two}" gw "$@" fi - if [ -n "${metric}" ] ; then - set -- "$@" metric ${metric} - fi + case "$@" in + *:*) + inet6="-A inet6" + [ "$1" = "-net" ] && shift + ;; + esac - route add "$@" + route ${inet6} add "$@" dev "${IFACE}" } _delete_addresses() { diff --git a/net.Linux/iproute2.sh b/net.Linux/iproute2.sh index 30206d03..fa1171d4 100644 --- a/net.Linux/iproute2.sh +++ b/net.Linux/iproute2.sh @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 iproute2_depend() { - program /sbin/ip + program /sbin/ip provide interface after ifconfig } |