aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthomas <thomas@b067294f-1dea-0310-9683-c47a78595994>2008-04-08 14:40:57 +0000
committerthomas <thomas@b067294f-1dea-0310-9683-c47a78595994>2008-04-08 14:40:57 +0000
commitec1f13213d985e5f931387bbb9f8b0bea0cab1d0 (patch)
treed94971df203d32d74ffbcade92f3659d38fed49f
parent62a3290eae0522b92d8d22a08ccf8596804072c5 (diff)
downloadxsettings-daemon-ec1f13213d985e5f931387bbb9f8b0bea0cab1d0.tar.gz
xsettings-daemon-ec1f13213d985e5f931387bbb9f8b0bea0cab1d0.tar.bz2
xsettings-daemon-ec1f13213d985e5f931387bbb9f8b0bea0cab1d0.zip
2008-04-08 Thomas Wood <thomas@openedhand.com>
* settings-daemon.c: (main): Fork only after settings have been applied git-svn-id: https://svn.o-hand.com/repos/matchbox/trunk/settings-daemon@2006 b067294f-1dea-0310-9683-c47a78595994
-rw-r--r--ChangeLog4
-rw-r--r--settings-daemon.c51
2 files changed, 30 insertions, 25 deletions
diff --git a/ChangeLog b/ChangeLog
index 171aeed..3a3b850 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2008-04-08 Thomas Wood <thomas@openedhand.com>
+
+ * settings-daemon.c: (main): Fork only after settings have been applied
+
2008-01-24 Ross Burton <ross@openedhand.com>
* settings-daemon.c:
diff --git a/settings-daemon.c b/settings-daemon.c
index 78bdf5a..791ac17 100644
--- a/settings-daemon.c
+++ b/settings-daemon.c
@@ -681,31 +681,6 @@ main(int argc, char **argv)
int i, n_screens;
pid_t p;
- if (!(argc > 1 && !strcmp(argv[1],"-n")))
- {
-
- g_print("[settings daemon] Forking. run with -n to prevent fork\n");
-
- p = fork();
-
- switch (p)
- {
- case -1:
- g_error("Fork failed.\n");
- break;
- case 0:
- /* child */
- /*
- fclose( stdin );
- fclose( stdout );
- */
- break;
- default:
- exit(0);
- break;
- }
- }
-
g_type_init();
gdk_init(&argc, &argv);
@@ -762,6 +737,32 @@ main(int argc, char **argv)
else g_error ("Failed to initialise gconf client");
+ if (!(argc > 1 && !strcmp(argv[1],"-n")))
+ {
+
+ g_print("[settings daemon] Forking. run with -n to prevent fork\n");
+
+ p = fork();
+
+ switch (p)
+ {
+ case -1:
+ g_error("Fork failed.\n");
+ break;
+ case 0:
+ /* child */
+ /*
+ fclose( stdin );
+ fclose( stdout );
+ */
+ break;
+ default:
+ exit(0);
+ break;
+ }
+ }
+
+
g_main_loop_run(loop);
g_object_unref (gconf_client);