]> git.pld-linux.org Git - packages/PowerChutePlus.git/commitdiff
- LSB conformance
authorankry <ankry@pld-linux.org>
Sun, 25 May 2003 16:18:46 +0000 (16:18 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    upsd.init -> 1.3

upsd.init

index e3b3e9002bad67b314509d1b2fdf03d5bcf31675..ce6ad07647e543962d7f8e129aef6ecd47ac52b6 100644 (file)
--- a/upsd.init
+++ b/upsd.init
@@ -32,7 +32,7 @@ if [ -r /upsoff.cmd ]; then
        rm -f /upsoff.cmd
 fi
 
-
+RETVAL=0
 # See how we were called.
 case "$1" in
   start)
@@ -45,7 +45,6 @@ case "$1" in
                [ $RETVAL -eq 0 ] && touch /var/lock/subsys/upsd
        else
                msg_already_running UPSd
-               exit 1
        fi
        ;;
   stop)
@@ -55,25 +54,20 @@ case "$1" in
                rm -f /var/lock/subsys/upsd >/dev/null 2>&1
        else
                msg_not_running UPSd
-               exit 1
        fi      
        ;;
   status)
        status upsd
+       exit $?
        ;;
-  restart|reload)
+  restart|force-reload)
        $0 stop
        $0 start
        exit $?
        ;;
-  force-reload)
-       $0 stop && $0 start
-       exit $?
-       ;;
   *)
-       msg_usage "$0 {start|stop|restart|reload|force-reload|status}"
-       exit 1
-       ;;
+       msg_usage "$0 {start|stop|restart|force-reload|status}"
+       exit 3
 esac
 
 exit $RETVAL
This page took 0.074456 seconds and 4 git commands to generate.