SOURCES: rpcsvcgssd.init - use functions
glen
glen at pld-linux.org
Fri Apr 6 12:24:14 CEST 2007
Author: glen Date: Fri Apr 6 10:24:14 2007 GMT
Module: SOURCES Tag: HEAD
---- Log message:
- use functions
---- Files affected:
SOURCES:
rpcsvcgssd.init (1.9 -> 1.10)
---- Diffs:
================================================================
Index: SOURCES/rpcsvcgssd.init
diff -u SOURCES/rpcsvcgssd.init:1.9 SOURCES/rpcsvcgssd.init:1.10
--- SOURCES/rpcsvcgssd.init:1.9 Fri Apr 6 01:43:11 2007
+++ SOURCES/rpcsvcgssd.init Fri Apr 6 12:24:09 2007
@@ -34,11 +34,7 @@
# List of kernel modules to load
[ -z "${SECURE_NFS_MODS}" ] && SECURE_NFS_MODS="des rpcsec_gss_krb5"
-RETVAL=0
-
-# See how we were called.
-case "$1" in
- start)
+start() {
# Check if the service is already running?
if [ ! -f /var/lock/subsys/svcgssd ]; then
# We need /proc/fs/nfsd mounted before starting svcgssd
@@ -57,8 +53,9 @@
else
msg_already_running "RPC svcgssd"
fi
- ;;
- stop)
+}
+
+stop() {
if [ -f /var/lock/subsys/svcgssd ]; then
msg_stopping "RPC svcgssd"
killproc rpc.svcgssd
@@ -66,15 +63,24 @@
else
msg_not_running "RPC svcgssd"
fi
+}
+
+# See how we were called.
+RETVAL=0
+case "$1" in
+ start)
+ start
+ ;;
+ stop)
+ stop
;;
status)
status rpc.svcgssd
RETVAL=$?
;;
restart|reload)
- $0 stop
- $0 start
- RETVAL=$?
+ stop
+ start
;;
*)
msg_usage "$0 {start|stop|restart|status}"
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SOURCES/rpcsvcgssd.init?r1=1.9&r2=1.10&f=u
More information about the pld-cvs-commit
mailing list