[prev in list] [next in list] [prev in thread] [next in thread] 

List:       squirrelmail-cvs
Subject:    [SM-CVS] SF.net SVN: squirrelmail:[14560] trunk/imap_proxy/src/main.c
From:       pdontthink () users ! sourceforge ! net
Date:       2016-09-12 18:52:06
Message-ID: E1bjWKw-0006Nc-3n () sfs-ml-4 ! v29 ! ch3 ! sourceforge ! com
[Download RAW message or body]

Revision: 14560
          http://sourceforge.net/p/squirrelmail/code/14560
Author:   pdontthink
Date:     2016-09-12 18:52:05 +0000 (Mon, 12 Sep 2016)
Log Message:
-----------
Fix startup issues under systemd (please let us know if this breaks other contexts)

Modified Paths:
--------------
    trunk/imap_proxy/src/main.c

Modified: trunk/imap_proxy/src/main.c
===================================================================
--- trunk/imap_proxy/src/main.c	2016-09-12 17:10:30 UTC (rev 14559)
+++ trunk/imap_proxy/src/main.c	2016-09-12 18:52:05 UTC (rev 14560)
@@ -969,7 +969,11 @@
  int i;
 
     /* detach from our parent if necessary */
-    if (! (getppid() == 1) && ( ! PC_Struct.foreground_mode ) )
+    // NOTE: When started under systemd, the parent PID is already 1, so
+    //       the safety check below of the parent PID causes imap_proxy
+    //       to start in foreground mode. I'm commenting it out, hoping
+    //       it doesn't cause issues in other contexts
+    if (/*! (getppid() == 1) &&*/ ( ! PC_Struct.foreground_mode ) )
     {
 	syslog( LOG_INFO, "%s: Configured to run in background mode.", fn );
 

This was sent by the SourceForge.net collaborative development platform, the world's \
largest Open Source development site.


------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity 
planning reports. http://sdm.link/zohodev2dev
-----
squirrelmail-cvs mailing list
List address: squirrelmail-cvs@lists.sourceforge.net
List info (subscribe/unsubscribe/change options): \
                https://lists.sourceforge.net/lists/listinfo/squirrelmail-cvs
Repository: http://squirrelmail.org/svn


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic