]> git.pld-linux.org Git - packages/courier-imap.git/blobdiff - courier-imap.init
- cleaning
[packages/courier-imap.git] / courier-imap.init
index 024f41334a51cd435a3b4f1bc6b864861c450d32..1905c0409a9538bbdb5ed2b781470e433486f97e 100644 (file)
@@ -21,9 +21,13 @@ IMAPDSSLSTART="no"
 [ -f /etc/sysconfig/courier-imap ] && . /etc/sysconfig/courier-imap
 
 # Check that networking is up.
-if is_no "${NETWORKING}" ; then
-       msg_network_down "Courier IMAP"
-       exit 1
+if is_yes "${NETWORKING}"; then
+       if [ ! -f /var/lock/subsys/network ]; then
+               msg_network_down "Courier IMAP"
+               exit 1
+       fi
+else
+       exit 0
 fi
 
 # See how we were called.
@@ -33,14 +37,14 @@ case "$1" in
        if [ ! -f /var/lock/subsys/courier-imap ]; then
                # start authdaemon, if not running..
                if [ ! -f /var/lock/subsys/authdaemon -a \
-                    -x /etc/rc.d/init.d/authdaemon ]; then
-                           /etc/rc.d/init.d/authdaemon start
-                           RETVAL=$?
-                           if [ $RETVAL -ne 0 ]; then
-                                   msg_starting "Courier IMAP"
-                                   fail
-                                   exit 1
-                           fi
+                  -x /etc/rc.d/init.d/authdaemon ]; then
+                       /etc/rc.d/init.d/authdaemon start
+                       RETVAL=$?
+                       if [ $RETVAL -ne 0 ]; then
+                               msg_starting "Courier IMAP"
+                               fail
+                               exit 1
+                       fi
                fi
                msg_starting "Courier IMAP"
                ulimit -d $IMAP_ULIMITD
This page took 0.056766 seconds and 4 git commands to generate.