From: Aleksander Morgado Date: Thu, 7 Feb 2013 09:54:24 +0000 (+0100) Subject: gdbusobjectmanagerclient: always connect to proxy's 'g-signal' X-Git-Tag: 2.35.8~18 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=27ecab75538a47ed89b78b4c212d870a9be60bac;p=platform%2Fupstream%2Fglib.git gdbusobjectmanagerclient: always connect to proxy's 'g-signal' If we don't connect to the control proxy's 'g-signal' signal, we won't have 'object-added' or 'object-removed' signals. So, connect to the 'g-signal' not only when there already is a name-owner, but always. https://bugzilla.gnome.org/show_bug.cgi?id=693285 --- diff --git a/gio/gdbusobjectmanagerclient.c b/gio/gdbusobjectmanagerclient.c index b77558b..5a60281 100644 --- a/gio/gdbusobjectmanagerclient.c +++ b/gio/gdbusobjectmanagerclient.c @@ -1352,6 +1352,11 @@ initable_init (GInitable *initable, G_CALLBACK (on_notify_g_name_owner), manager); + g_signal_connect (manager->priv->control_proxy, + "g-signal", + G_CALLBACK (on_control_proxy_g_signal), + manager); + manager->priv->name_owner = g_dbus_proxy_get_name_owner (manager->priv->control_proxy); if (manager->priv->name_owner == NULL && manager->priv->name != NULL) { @@ -1362,10 +1367,6 @@ initable_init (GInitable *initable, else { /* yay, we can get the objects */ - g_signal_connect (manager->priv->control_proxy, - "g-signal", - G_CALLBACK (on_control_proxy_g_signal), - manager); subscribe_signals (manager, manager->priv->name_owner); value = g_dbus_proxy_call_sync (manager->priv->control_proxy,