summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorerdgeist <>2013-03-13 13:03:19 +0000
committererdgeist <>2013-03-13 13:03:19 +0000
commit18d42bba70a91e85130f611afb1fe38ea76af3e3 (patch)
tree50065de5165f55c59d534ddd8d7e180833abea97
parentd170c239211b5d19b222627b7ee476c1e851895d (diff)
Comments and formatting
-rw-r--r--jaildaemon.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/jaildaemon.c b/jaildaemon.c
index b15a253..9e2f6f7 100644
--- a/jaildaemon.c
+++ b/jaildaemon.c
@@ -478,11 +478,9 @@ int main( int argc, char **argv ) {
478 exit(0); 478 exit(0);
479 } 479 }
480 480
481 /* This utility mode code finished with the exit(0) above. We're daemon. */ 481 /* The utility mode code finished with the exit(0) above. We're daemon. */
482 482
483 /* Daemonize and start a fork slave while there is no file descriptors or 483 if( !( g_pidfilehandle = pidfile_open(o_pidfile, 0600, &second_pid ) ) ) {
484 initialized memory yet. Communicate with this slave via socketpair */
485 if( !( g_pidfilehandle = pidfile_open(o_pidfile, 0600, &second_pid ) ) ) {
486 if (errno == EEXIST) 484 if (errno == EEXIST)
487 exerr( "jaildaemon already running." ); 485 exerr( "jaildaemon already running." );
488 486
@@ -502,6 +500,8 @@ int main( int argc, char **argv ) {
502 warn( "Forcing start of daemon despite working command channel." ); 500 warn( "Forcing start of daemon despite working command channel." );
503 } 501 }
504 502
503 /* Daemonize and start a fork slave while there is no file descriptors or
504 initialized memory yet. Communicate with this slave via socketpair */
505 if( daemon(1,0) == -1 ) { 505 if( daemon(1,0) == -1 ) {
506 pidfile_remove(g_pidfilehandle); 506 pidfile_remove(g_pidfilehandle);
507 exerr( "daemonzing" ); 507 exerr( "daemonzing" );