diff options
author | William Jon McCann <mccann@jhu.edu> | 2007-04-03 12:25:18 -0400 |
---|---|---|
committer | William Jon McCann <mccann@jhu.edu> | 2007-04-03 12:25:18 -0400 |
commit | f073826f58541cbbe2b805f200a9d245d76c634c (patch) | |
tree | 6a7d1aa60f7afee124b1b51d332acaa1371e691e /src/main.c | |
parent | 80dc652115e275a95b05bb6809825cc324d9475a (diff) |
daemonize a little earlier
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -288,6 +288,10 @@ main (int argc, g_option_context_parse (context, &argc, &argv, NULL); g_option_context_free (context); + if (! no_daemon && daemon (0, 0)) { + g_error ("Could not daemonize: %s", g_strerror (errno)); + } + setup_debug_log (debug); connection = get_system_bus (); @@ -308,10 +312,6 @@ main (int argc, g_debug ("initializing console-kit-daemon %s", VERSION); - if (! no_daemon && daemon (0, 0)) { - g_error ("Could not daemonize: %s", g_strerror (errno)); - } - /* remove old pid file */ unlink (CONSOLE_KIT_PID_FILE); |