core: use wrappers for DBus object registration/unregistration

When providing a service on the bus daemon and a private connection,
we'll need to track objects so we can register them with the
private connection too.  Thus all registration/unregistration
calls have to go through the NMDBusManager, not straight to
dbus-glib.
This commit is contained in:
Dan Williams
2012-10-04 16:42:03 -05:00
parent 1fec50cc1e
commit 3c7f267fb9
12 changed files with 73 additions and 48 deletions

View File

@@ -217,8 +217,7 @@ nm_active_connection_export (NMActiveConnection *self)
priv->path = g_strdup_printf (NM_DBUS_PATH "/ActiveConnection/%d", counter++);
dbus_mgr = nm_dbus_manager_get ();
dbus_g_connection_register_g_object (nm_dbus_manager_get_connection (dbus_mgr),
priv->path, G_OBJECT (self));
nm_dbus_manager_register_object (dbus_mgr, priv->path, self);
g_object_unref (dbus_mgr);
}