summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@orbis-terrarum.net>2010-12-15 12:40:21 -0800
committerRobin H. Johnson <robbat2@orbis-terrarum.net>2010-12-15 12:40:21 -0800
commit346148ceb8c67fb2eb26c9bf5484e6c49a138a49 (patch)
treefa820143ef8b83ce3ca262d84211ebbbabfbe94d
parent12a91636f43276c984487daef5b39e6d64603165 (diff)
downloadopenrc-346148ceb8c67fb2eb26c9bf5484e6c49a138a49.tar.gz
openrc-346148ceb8c67fb2eb26c9bf5484e6c49a138a49.tar.bz2
openrc-346148ceb8c67fb2eb26c9bf5484e6c49a138a49.tar.xz
Fix pointopoint->peer for iproute.
-rw-r--r--net/iproute2.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/net/iproute2.sh b/net/iproute2.sh
index e89e33b..2087346 100644
--- a/net/iproute2.sh
+++ b/net/iproute2.sh
@@ -118,7 +118,12 @@ _add_address()
set -- "${one}/$(_netmask2cidr "${three}")" "$@"
fi
- #config=( "${config[@]//pointopoint/peer}" )
+ # tunnel keyword is 'peer' in iproute2, but 'pointopoint' in ifconfig.
+ if [ "$2" = "pointopoint" ]; then
+ local one="$1"
+ shift; shift
+ set -- "${one}" "peer" "$@"
+ fi
# Always scope lo addresses as host unless specified otherwise
if [ "${IFACE}" = "lo" ]; then