diff options
author | Judd Vinet <judd@archlinux.org> | 2002-07-24 02:57:16 +0000 |
---|---|---|
committer | Judd Vinet <judd@archlinux.org> | 2002-07-24 02:57:16 +0000 |
commit | fd8fde036ab46b593590b362bc94b051e432a295 (patch) | |
tree | 06fe9bb2ce1828ea03261828ee5eda6d7e751517 /network | |
parent | 2b503065569fa2ffedf5eafc76158c74062ac49b (diff) |
Upgraded initscripts to 0.30.3
Diffstat (limited to 'network')
-rwxr-xr-x | network | 16 |
1 files changed, 10 insertions, 6 deletions
@@ -6,6 +6,7 @@ case "$1" in start) + ck_daemon network || exit stat_busy "Starting Network" for ifline in ${INTERFACES[@]}; do if echo $ifline | grep '^[^\!]' 2>&1 > /dev/null; then @@ -15,7 +16,7 @@ case "$1" in /usr/sbin/dhcpcd $ifline || stat_die else /sbin/ifconfig $new_ifline || stat_die - fi + fi fi done for rtline in "${ROUTES[@]}"; do @@ -25,10 +26,13 @@ case "$1" in /sbin/route add $new_rtline || stat_die fi done + add_daemon network stat_done ;; stop) + ck_daemon network && exit stat_busy "Stopping Network" + rm_daemon network for rtline in "${ROUTES[@]}"; do if echo $rtline | grep '^[^\!]' 2>&1 > /dev/null; then varname="\$${rtline}" @@ -40,12 +44,12 @@ case "$1" in if echo $ifline | grep '^[^\!]' 2>&1 > /dev/null; then varname="\$${ifline}" eval new_ifline=$varname - if [ "$new_ifline" = "dhcp" ]; then - # do nothing - we kill dhcpcd later - /bin/true - else + if [ "$new_ifline" = "dhcp" ]; then + # do nothing - we kill dhcpcd later + /bin/true + else /sbin/ifconfig $new_ifline down || stat_die - fi + fi fi done /usr/bin/killall -q dhcpcd |