|
@@ -1,16 +1,16 @@
|
|
#!/bin/sh
|
|
#!/bin/sh
|
|
|
|
|
|
-DAEMON="/usr/libexec/iwd"
|
|
|
|
-PIDFILE="/var/run/iwd.pid"
|
|
|
|
|
|
+DAEMON="iwd"
|
|
|
|
+PIDFILE="/var/run/$DAEMON.pid"
|
|
|
|
|
|
IWD_ARGS=""
|
|
IWD_ARGS=""
|
|
|
|
|
|
-[ -r "/etc/default/iwd" ] && . "/etc/default/iwd"
|
|
|
|
|
|
+[ -r "/etc/default/$DAEMON" ] && . "/etc/default/$DAEMON"
|
|
|
|
|
|
start() {
|
|
start() {
|
|
- printf "Starting iwd:"
|
|
|
|
|
|
+ printf 'Starting %s: ' "$DAEMON"
|
|
mkdir -p /tmp/iwd/hotspot
|
|
mkdir -p /tmp/iwd/hotspot
|
|
- start-stop-daemon -b -m -S -q -p "$PIDFILE" -x "$DAEMON" \
|
|
|
|
|
|
+ start-stop-daemon -b -m -S -q -p "$PIDFILE" -x "/usr/libexec/$DAEMON" \
|
|
-- $IWD_ARGS
|
|
-- $IWD_ARGS
|
|
status=$?
|
|
status=$?
|
|
if [ "$status" -eq 0 ]; then
|
|
if [ "$status" -eq 0 ]; then
|
|
@@ -22,7 +22,7 @@ start() {
|
|
}
|
|
}
|
|
|
|
|
|
stop() {
|
|
stop() {
|
|
- printf "Stopping iwd:"
|
|
|
|
|
|
+ printf 'Stopping %s: ' "$DAEMON"
|
|
start-stop-daemon -K -q -p "$PIDFILE"
|
|
start-stop-daemon -K -q -p "$PIDFILE"
|
|
status=$?
|
|
status=$?
|
|
if [ "$status" -eq 0 ]; then
|
|
if [ "$status" -eq 0 ]; then
|