From 758a4880f645242f1c7753990dc46f880a7e9de8 Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Thu, 17 Oct 2013 17:48:06 -0500 Subject: cleanup: dead code removal, fix comments, smaller implementation of update_internal_localtime() --- src/main.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/main.c') diff --git a/src/main.c b/src/main.c index 9305794..dc08419 100644 --- a/src/main.c +++ b/src/main.c @@ -59,17 +59,19 @@ main (int argc G_GNUC_UNUSED, char ** argv G_GNUC_UNUSED) if (!notify_init ("indicator-datetime-service")) g_critical ("libnotify initialization failed"); - /* run */ + /* create the service */ clock = indicator_datetime_clock_live_new (); planner = indicator_datetime_planner_eds_new (); service = indicator_datetime_service_new (clock, planner); + + /* run */ loop = g_main_loop_new (NULL, FALSE); g_signal_connect (service, INDICATOR_DATETIME_SERVICE_SIGNAL_NAME_LOST, G_CALLBACK(on_name_lost), loop); g_main_loop_run (loop); + g_main_loop_unref (loop); /* cleanup */ - g_main_loop_unref (loop); g_object_unref (service); g_object_unref (planner); g_object_unref (clock); -- cgit v1.2.3