diff options
author | Vasilis Tsiligiannis <acinonyx@openwrt.gr> | 2011-09-14 13:37:44 +0000 |
---|---|---|
committer | Vasilis Tsiligiannis <acinonyx@openwrt.gr> | 2011-09-14 13:37:44 +0000 |
commit | 98372a8eb51cafa81f0e31672669dc23d745d109 (patch) | |
tree | 16746edc36f530dbc6b04b3196b1f6fac4e4cc2c | |
parent | 200fd7bce1013e4830cc799cf3ff0a24c502a77f (diff) | |
download | upstream-98372a8eb51cafa81f0e31672669dc23d745d109.tar.gz upstream-98372a8eb51cafa81f0e31672669dc23d745d109.tar.bz2 upstream-98372a8eb51cafa81f0e31672669dc23d745d109.zip |
base-files: Fix IPv6 address and route adding on aliases with no IPv4 address configured
SVN-Revision: 28241
-rwxr-xr-x | package/base-files/files/lib/network/config.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/package/base-files/files/lib/network/config.sh b/package/base-files/files/lib/network/config.sh index cf5b197b59..5b349a7387 100755 --- a/package/base-files/files/lib/network/config.sh +++ b/package/base-files/files/lib/network/config.sh @@ -261,9 +261,9 @@ setup_interface_static() { esac [ -z "$ipaddr" ] || $DEBUG ifconfig "$iface" "$ipaddr" netmask "$netmask" broadcast "${bcast:-+}" - [ -z "$ip6addr" ] || $DEBUG ifconfig "$iface" add "$ip6addr" + [ -z "$ip6addr" ] || $DEBUG ifconfig "${iface%:*}" add "$ip6addr" [ -z "$gateway" ] || $DEBUG route add default gw "$gateway" ${metric:+metric $metric} dev "$iface" - [ -z "$ip6gw" ] || $DEBUG route -A inet6 add default gw "$ip6gw" ${metric:+metric $metric} dev "$iface" + [ -z "$ip6gw" ] || $DEBUG route -A inet6 add default gw "$ip6gw" ${metric:+metric $metric} dev "${iface%:*}" [ -z "$dns" ] || add_dns "$config" $dns config_get type "$config" TYPE |