X-Git-Url: http://git.archive.openwrt.org/?a=blobdiff_plain;f=sound%2Fmt-daapd%2Ffiles%2Fmt-daapd.init;fp=sound%2Fmt-daapd%2Ffiles%2Fmt-daapd.init;h=344621a41ae3545451b691d555f4c43f0e8d9652;hb=8b12dd0b904b0a4bf2c2a894ccbf780f796e58ba;hp=2968769c782ba9bcc392bf7a61f03da271800f29;hpb=2295d502f6ab93d47586794351463f3b7d03753a;p=packages.git diff --git a/sound/mt-daapd/files/mt-daapd.init b/sound/mt-daapd/files/mt-daapd.init index 2968769c7..344621a41 100644 --- a/sound/mt-daapd/files/mt-daapd.init +++ b/sound/mt-daapd/files/mt-daapd.init @@ -1,4 +1,5 @@ -#!/bin/sh +#!/bin/sh /etc/rc.common +# Copyright (C) 2006 OpenWrt.org BIN=mt-daapd DEFAULT=/etc/default/$BIN @@ -6,17 +7,12 @@ RUN_D=/var/run PID_F=$RUN_D/$BIN.pid [ -f $DEFAULT ] && . $DEFAULT -case $1 in - start) - [ -d $RUN_D ] || mkdir -p $RUN_D - $BIN $OPTIONS - ;; - stop) - [ -f $PID_F ] && kill -INT $(cat $PID_F) - ;; - *) - echo "usage: $0 (start|stop)" - exit 1 -esac +start() { + [ -d $RUN_D ] || mkdir -p $RUN_D + $BIN $OPTIONS +} + +stop() { + [ -f $PID_F ] && kill -INT $(cat $PID_F) +} -exit $?