summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings2/etc_ppp/ip-up_down/U_Routes
Unidiff
Diffstat (limited to 'noncore/settings/networksettings2/etc_ppp/ip-up_down/U_Routes') (more/less context) (show whitespace changes)
-rwxr-xr-xnoncore/settings/networksettings2/etc_ppp/ip-up_down/U_Routes30
1 files changed, 30 insertions, 0 deletions
diff --git a/noncore/settings/networksettings2/etc_ppp/ip-up_down/U_Routes b/noncore/settings/networksettings2/etc_ppp/ip-up_down/U_Routes
new file mode 100755
index 0000000..afefc49
--- a/dev/null
+++ b/noncore/settings/networksettings2/etc_ppp/ip-up_down/U_Routes
@@ -0,0 +1,30 @@
1#!/bin/sh
2exec 2> /tmp/ROUTE
3set -x
4CMD=`basename $0`
5FIXED=/etc/ppp/$6.fixed
6
7case $CMD in
8 U_*)
9 if [ -f $FIXED ]
10 then
11 # ADD FIXED routes
12 grep "route add " $FIXED > /tmp/xx
13 fi
14 ;;
15 D_*)
16 if [ -f $FIXED ]
17 then
18 grep "route del " $FIXED > /tmp/xx
19 fi
20 ;;
21esac
22
23if [ -f /tmp/xx ]
24then
25 . /tmp/xx
26 rm /tmp/xx
27fi
28
29exit 0
30