[packages] portmap fixes:
[openwrt/svn-archive/archive.git] / net / portmap / files / portmap.init
index f42eabb366d54a38a0a2f9a2753ac0a6b12189e5..97ee0d706ae4a00e16f01f500f94b560c7976b7b 100644 (file)
@@ -1,16 +1,16 @@
 #!/bin/sh /etc/rc.common
-# Copyright (C) 2006 OpenWrt.org
+# Copyright (C) 2006-2008 OpenWrt.org
 
 START=40
-BIN=portmap
-DEFAULT=/etc/default/$BIN
+NAME=portmap
+PROG=/usr/sbin/$NAME
+DEFAULT=/etc/default/$NAME
 
 start() {
        [ -f $DEFAULT ] && . $DEFAULT
-       $BIN -u 0 -g 0 $OPTIONS
+       start-stop-daemon -q -S -x $PROG -- $OPTIONS
 }
 
 stop() {
-       killall $BIN
+       start-stop-daemon -q -K -x $PROG -- $OPTIONS
 }
-