tags 500571 patch
thanks
Use LSB logging functions to ensure use of uniform output style in the future.
Depend on lsb-base (>= 3.0-6).
Log interface name before daemon performs action, so that errors can be
identified with a specific interface easily.
Closes: #500571
---
--- a/debian/control
+++ b/debian/control
@@ -11,7 +11,7 @@
Package: ifplugd
Architecture: any
-Depends: ${shlibs:Depends}, debconf (>= 1.2.0) | debconf-2.0
+Depends: ${shlibs:Depends}, debconf (>= 1.2.0) | debconf-2.0, lsb-base (>=
3.0-6)
Recommends: ifupdown (>= 0.6.4-4.2)
Suggests: wpasupplicant, waproamd
Description: configuration daemon for ethernet devices
--- a/debian/ifplugd.init
+++ b/debian/ifplugd.init
@@ -49,49 +49,52 @@
[ "$INTERFACES" ] || exit 0
+. /lib/lsb/init-functions
+
case "$VERB" in
start)
- echo -n "Starting Network Interface Plugging Daemon:"
+ log_daemon_msg "Starting Network Interface Plugging Daemon"
for IF in $INTERFACES ; do
grep --quiet $IF /proc/net/dev || continue
+ log_progress_msg "$IF"
IF1=$(echo $IF | sed "s/-/_/")
A=$(eval echo \$\{ARGS_${IF1}\})
[ -z "$A" ] && A="$ARGS"
$IFPLUGD -i $IF $A
- echo -n " $IF"
done
- echo "."
+ log_end_msg 0
;;
stop)
- echo -n "Stopping Network Interface Plugging Daemon:"
+ log_daemon_msg "Stopping Network Interface Plugging Daemon"
for IF in $INTERFACES ; do
grep --quiet $IF /proc/net/dev || continue
+ log_progress_msg "$IF"
$IFPLUGD -k --wait-on-kill -i $IF
- echo -n " $IF"
done
- echo "."
+ log_end_msg 0
;;
status)
for IF in $INTERFACES ; do
+ log_begin_msg "$IF: "
$IFPLUGD -c -i $IF
done
;;
suspend)
- echo -n "Suspending Network Interface Plugging Daemon:"
+ log_daemon_msg "Suspending Network Interface Plugging Daemon"
for IF in $INTERFACES ; do
grep --quiet $IF /proc/net/dev || continue
+ log_progress_msg "$IF"
$IFPLUGD -S -i $IF
- echo -n " $IF"
done
- echo "."
+ log_end_msg 0
;;
resume)
- echo -n "Resuming Network Interface Plugging Daemon:"
+ log_daemon_msg "Resuming Network Interface Plugging Daemon"
for IF in $INTERFACES ; do
+ log_progress_msg "$IF"
$IFPLUGD -R -i $IF
- echo -n " $IF"
done
- echo "."
+ log_end_msg 0
;;
force-reload|restart)
$0 stop $INTERFACES
---
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]