diff options
author | Bastien Nocera <hadess@hadess.net> | 2014-07-21 16:09:13 +0200 |
---|---|---|
committer | Bastien Nocera <hadess@hadess.net> | 2014-08-12 23:56:38 +0200 |
commit | 620645541dc0a4ad58f1dbd65a3bf6a9549ac81d (patch) | |
tree | 46fe8807815de3d2aba10ea1ae76b4c6c3f3371f | |
parent | a1b76323d4f2668bfdf163e76da944ea7a988931 (diff) | |
download | gnome-settings-daemon-620645541dc0a4ad58f1dbd65a3bf6a9549ac81d.tar.gz |
orientation: Unown the D-Bus name on Stop
Instead of when finalizing the plugin, so that stop and starting
the plugin again works as expected.
-rw-r--r-- | plugins/orientation/gsd-orientation-manager.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/orientation/gsd-orientation-manager.c b/plugins/orientation/gsd-orientation-manager.c index e325c950..f02d192e 100644 --- a/plugins/orientation/gsd-orientation-manager.c +++ b/plugins/orientation/gsd-orientation-manager.c @@ -458,6 +458,9 @@ gsd_orientation_manager_stop (GsdOrientationManager *manager) g_debug ("Stopping orientation manager"); + if (manager->priv->name_id != 0) + g_bus_unown_name (manager->priv->name_id); + g_clear_object (&p->settings); g_clear_pointer (&p->sysfs_path, g_free); g_clear_pointer (&p->introspection_data, g_dbus_node_info_unref); @@ -479,9 +482,6 @@ gsd_orientation_manager_finalize (GObject *object) if (orientation_manager->priv->start_idle_id != 0) g_source_remove (orientation_manager->priv->start_idle_id); - if (orientation_manager->priv->name_id != 0) - g_bus_unown_name (orientation_manager->priv->name_id); - G_OBJECT_CLASS (gsd_orientation_manager_parent_class)->finalize (object); } |