From fce49b89f9e5e0f864b7f2d7fbda69397a575ed4 Mon Sep 17 00:00:00 2001 From: Pierre-Luc Beaudoin Date: Mon, 1 Jun 2009 13:39:38 -0400 Subject: Fix Bug 584518: Critical error in publish_to_all_connections The account_manager was initialised after the callbacks were. --- libempathy-gtk/empathy-location-manager.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libempathy-gtk') diff --git a/libempathy-gtk/empathy-location-manager.c b/libempathy-gtk/empathy-location-manager.c index 436e0a216..1bb1b732f 100644 --- a/libempathy-gtk/empathy-location-manager.c +++ b/libempathy-gtk/empathy-location-manager.c @@ -628,6 +628,12 @@ empathy_location_manager_init (EmpathyLocationManager *location_manager) priv->location = g_hash_table_new_full (g_direct_hash, g_direct_equal, g_free, (GDestroyNotify) tp_g_value_slice_free); + /* Setup account status callbacks */ + priv->account_manager = empathy_account_manager_dup_singleton (); + g_signal_connect (priv->account_manager, + "new-connection", + G_CALLBACK (new_connection_cb), location_manager); + /* Setup settings status callbacks */ conf = empathy_conf_get (); empathy_conf_notify_add (conf, EMPATHY_PREFS_LOCATION_PUBLISH, publish_cb, @@ -646,12 +652,6 @@ empathy_location_manager_init (EmpathyLocationManager *location_manager) resource_cb (conf, EMPATHY_PREFS_LOCATION_RESOURCE_GPS, location_manager); accuracy_cb (conf, EMPATHY_PREFS_LOCATION_REDUCE_ACCURACY, location_manager); publish_cb (conf, EMPATHY_PREFS_LOCATION_PUBLISH, location_manager); - - /* Setup account status callbacks */ - priv->account_manager = empathy_account_manager_dup_singleton (); - g_signal_connect (priv->account_manager, - "new-connection", - G_CALLBACK (new_connection_cb), location_manager); } EmpathyLocationManager * -- cgit v1.2.3