gio: avoid g_object_ref(NULL) in g_dbus_object_manager_client_finalize

When establishing a D-Bus connection failed, g_dbus_object_manager_client_finalize()
calls g_object_ref(manager->priv->connection) when that pointer is NULL,
which is considered and logged as error by glib.

https://bugzilla.gnome.org/show_bug.cgi?id=732984
This commit is contained in:
SyncEvolution Nightly Testing 2014-07-10 09:52:26 +00:00 committed by Matthias Clasen
parent b458d3da32
commit f62c8fce8e

View File

@ -204,7 +204,8 @@ g_dbus_object_manager_client_finalize (GObject *object)
manager);
g_object_unref (manager->priv->control_proxy);
}
g_object_unref (manager->priv->connection);
if (manager->priv->connection != NULL)
g_object_unref (manager->priv->connection);
g_free (manager->priv->object_path);
g_free (manager->priv->name);
g_free (manager->priv->name_owner);