summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-scripts/net/br2684ctl.sh')
-rw-r--r--net-scripts/net/br2684ctl.sh15
1 files changed, 7 insertions, 8 deletions
diff --git a/net-scripts/net/br2684ctl.sh b/net-scripts/net/br2684ctl.sh
index 445d2f1..e325817 100644
--- a/net-scripts/net/br2684ctl.sh
+++ b/net-scripts/net/br2684ctl.sh
@@ -35,16 +35,15 @@ br2684ctl_pre_start() {
return 1
fi
- if [[ " ${!opts} " != *" -b "* ]] ; then
- eerror "The -b option is not allowed for br2684ctl_${ifvar}"
+ if [[ " ${!opts} " == *" -b "* || " {!opts} " == *" -c "* ]] ; then
+ eerror "The -b and -c options are not allowed for br2684ctl_${ifvar}"
return 1
fi
einfo "Starting RFC 2684 Bridge control on ${iface}"
-
start-stop-daemon --start --exec /sbin/br2684ctl --background \
--make-pidfile --pidfile "/var/run/br2684ctl-${iface}.pid" \
- -- ${!opts} -c "${number}"
+ -- -c "${number}" ${!opts}
eend $?
}
@@ -52,14 +51,14 @@ br2684ctl_pre_start() {
br2684ctl_post_stop() {
local iface="$1"
local number="${iface#${iface%%[0-9]}}"
+ local pidfile="/var/run/br2684ctl-${iface}.pid"
- [[ $(itype "${iface}") != "nas" ]] && return 0
+ [[ $(interface_type "${iface}") != "nas" ]] && return 0
- [[ -e /var/run/br2864ctl-${iface}.pid ]] || return 0
+ [[ -e ${pidfile} ]] || return 0
einfo "Stopping RFC 2684 Bridge control on ${iface}"
- start-stop-daemon --stop --exec /sbin/br2864ctl \
- --pidfile "/var/run/br2684ctl-${iface}.pid"
+ start-stop-daemon --stop --exec /sbin/br2684ctl --pidfile "${pidfile}"
eend $?
}