port lots of init scripts over to rc.common (more to come)
[openwrt/svn-archive/archive.git] / net / frickin / files / frickin.init
index e07a0945b687e6417fe96f04dca83bc43d3ed1ca..73f183e6b42246be37ca46e63bf031c0ef85ef1e 100644 (file)
@@ -1,16 +1,15 @@
-#!/bin/sh
+#!/bin/sh /etc/rc.common
+# Copyright (C) 2006 OpenWrt.org
 
 BIN=frickin
 DEFAULT=/etc/default/$BIN
 [ -f $DEFAULT ] && . $DEFAULT
 
-case $1 in
- start)
-  $BIN $OPTIONS &
-  ;;
- *)
-  echo "usage: $0 (start)"
-  exit 1
-esac
+start() {
+       $BIN $OPTIONS &
+}
+
+stop() {
+       killall $BIN
+}
 
-exit $?