summaryrefslogtreecommitdiff
path: root/debian/ifplugd.udev.agent
diff options
context:
space:
mode:
authorY Giridhar Appaji Nag <giridhar@appaji.net>2008-05-16 22:02:59 +0530
committerAndrew Shadura <andrew.shadura@collabora.co.uk>2016-06-21 11:57:30 +0200
commit2b5e3b4a05357be92ce456723e2a5b43516a9f7e (patch)
tree84798d66983004663435458ac8556067f9593253 /debian/ifplugd.udev.agent
parent0c424a821a992853e0ae1689d3602694a469ba2a (diff)
Imported Debian patch 0.28-11
Diffstat (limited to 'debian/ifplugd.udev.agent')
-rw-r--r--debian/ifplugd.udev.agent10
1 files changed, 8 insertions, 2 deletions
diff --git a/debian/ifplugd.udev.agent b/debian/ifplugd.udev.agent
index fe02b51..60a232c 100644
--- a/debian/ifplugd.udev.agent
+++ b/debian/ifplugd.udev.agent
@@ -32,6 +32,9 @@ search_interfaces () {
return 1
}
+IFPLUGD=/usr/sbin/ifplugd
+test -x $IFPLUGD || exit 0
+
search_interfaces "$INTERFACE" "$INTERFACES"
if [ $? -gt 0 ] ; then
# Interface isn't statically managed by ifplugd
@@ -41,11 +44,14 @@ if [ $? -gt 0 ] ; then
case $ACTION in
add|register)
debug_mesg Invoking $DAEMON_NAME for $INTERFACE
- exec /etc/init.d/$DAEMON_NAME start $INTERFACE&
+ IF1=$(echo $INTERFACE | sed "s/-/_/")
+ A=$(eval echo \$\{ARGS_${IF1}\})
+ [ -z "$A" ] && A="$ARGS"
+ exec $IFPLUGD -i $INTERFACE $A &
;;
remove|unregister)
debug_mesg Stopping $DAEMON_NAME for $INTERFACE
- exec /etc/init.d/$DAEMON_NAME stop $INTERFACE&
+ exec $IFPLUGD -k --wait-on-kill -i $INTERFACE &
;;
esac
break