aboutsummaryrefslogtreecommitdiffstats
path: root/meta-cgl-common/recipes-cgl/racoon2/racoon2/racoon2-iked-initscript.patch
blob: 10182f3707ad3e9af9728cff2712d8d744448391 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
Source /etc/init.d/functions and add sub-command status

Upstream-Status: Inappropriate [embedded specific]

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>

diff --git a/samples/init.d-iked.in b/samples/init.d-iked.in
index 4e65b94..ff5f355 100644
--- a/samples/init.d-iked.in
+++ b/samples/init.d-iked.in
@@ -3,6 +3,9 @@
 # iked startup script
 #
 
+# Source function library.
+. /etc/init.d/functions
+
 prefix=@prefix@
 exec_prefix=@exec_prefix@
 
@@ -25,6 +28,10 @@ stop)
 	read pid junk < $PIDFILE && kill $pid
 	echo "."
 	;;
+  status)
+	status $DAEMON;
+	exit $?
+	;;
 restart)
 	$0 stop
 	$0 start
@@ -35,7 +42,7 @@ reload)
 	echo "."
 	;;
 *)
-	echo "usage: $0 {start|stop|restart|reload}"
+	echo "usage: $0 {start|stop|status|restart|reload}"
 	exit 1
 	;;
 esac