]> git.pld-linux.org Git - packages/fetchmail.git/commitdiff
- LSB conformance
authorankry <ankry@pld-linux.org>
Wed, 21 May 2003 21:45:52 +0000 (21:45 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    fetchmail.init -> 1.11

fetchmail.init

index c3505e4f6a121a844cb5e25a8be8834b50ae0980..99b7f4858e51e3084413b1fabba18f9d94680c7e 100644 (file)
@@ -33,6 +33,7 @@ fi
 # Check that fetchmailrc exists.
 [ -f /etc/fetchmailrc ] || exit 0
 
+RETVAL=0
 # See how we were called.
 case "$1" in
   start)
@@ -46,7 +47,6 @@ case "$1" in
                [ $RETVAL -eq 0 ] && touch /var/lock/subsys/fetchmail
        else
                msg_already_running fetchmail
-               exit 1
        fi
        ;;
   stop)
@@ -56,39 +56,30 @@ case "$1" in
                rm -f /var/lock/subsys/fetchmail >/dev/null 2>&1
        else
                msg_not_running "fetchmail"
-               exit 1
        fi      
        ;;
   restart)
        $0 stop
        $0 start
+       exit $?
        ;;
-  reload)
+  reload|force-reload)
        if [ -f /var/lock/subsys/fetchmail ]; then
                msg_reloading "fetchmail"
                killproc fetchmail -HUP
                RETVAL=$?
        else
-               msg_not_running fetchmail
-               exit 1
+               msg_not_running fetchmail >&2
+               exit 7
        fi
        ;;
-  force-reload)
-       # if program allows reloading without stopping
-       $0 reload
-       exit $?
-
-       # or if it doesn't
-       $0 stop && $0 start
-       exit $?
-       ;;
   status)
        status fetchmail
        exit $?
        ;;
   *)
        msg_usage "$0 {start|stop|restart|reload|force-reload|status}"
-       exit 1
+       exit 3
 esac
 
 exit $RETVAL
This page took 0.112105 seconds and 4 git commands to generate.