>From 7bf569404fe42b1e20f58088923f073d333cb370 Mon Sep 17 00:00:00 2001 From: Timothy Arceri Date: Wed, 17 Apr 2013 01:23:56 +1000 Subject: [PATCH] Adds remaining shutdown infrastructure https://bugzilla.gnome.org/show_bug.cgi?id=511802 --- daemon/daemon-main.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/daemon/daemon-main.c b/daemon/daemon-main.c index de007b0..0b25ab0 100644 --- a/daemon/daemon-main.c +++ b/daemon/daemon-main.c @@ -340,6 +340,14 @@ do_name_acquired (gpointer user_data) return FALSE; } +static void +daemon_shutdown (GVfsDaemon *daemon, + GMainLoop *loop) +{ + if (g_main_loop_is_running (loop)) + g_main_loop_quit (loop); +} + void daemon_main (int argc, char *argv[], @@ -391,6 +399,9 @@ daemon_main (int argc, { g_idle_add (do_name_acquired, data); } + + g_signal_connect (data->daemon, "shutdown", + G_CALLBACK (daemon_shutdown), loop); g_main_loop_run (loop); -- 1.8.1.2