source: freewrt/package/base-files/default/sbin/ifdown@ efcdba6

freewrt_1_0 freewrt_2_0
Last change on this file since efcdba6 was efcdba6, checked in by Waldemar Brodkorb <wbx@…>, 19 years ago

fix typo, fix from OpenWrt

git-svn-id: svn://www.freewrt.org/trunk/freewrt@227 afb5a338-a214-0410-bd46-81f09a774fd1

  • Property mode set to 100755
File size: 467 bytes
Line 
1#!/bin/sh
2[ $# = 0 ] && { echo " $0 <group>"; exit; }
3. /etc/functions.sh
4
5type=$1
6debug "### ifdown $type ###"
7
8if=$(nvram get ${type}_ifname)
9proto=$(nvram get ${type}_proto)
10if_valid $if && $DEBUG ifconfig $if down
11[ -r /var/run/${if}.pid ] && kill $(cat /var/run/${if}.pid 2>&-) 2>&-
12killall ifup.$proto >&- 2>&-
13case "$proto" in
14 pptp|pppoe) killall pppd >&- 2>&- ;;
15 static) env -i ACTION="ifdown" INTERFACE="$type" PROTO=static /sbin/hotplug "iface" ;;
16esac
17
Note: See TracBrowser for help on using the repository browser.