[gnome-settings-daemon/gnome-3-6] updates: Really cancel tasks on shutdown



commit 4ccc0bfaa6ffb83f5268288a6519007df993e3ae
Author: Bastien Nocera <hadess hadess net>
Date:   Fri Mar 8 11:19:35 2013 +0100

    updates: Really cancel tasks on shutdown

 plugins/updates/gsd-updates-manager.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/plugins/updates/gsd-updates-manager.c b/plugins/updates/gsd-updates-manager.c
index a0eea86..42adfa1 100644
--- a/plugins/updates/gsd-updates-manager.c
+++ b/plugins/updates/gsd-updates-manager.c
@@ -1477,7 +1477,10 @@ gsd_updates_manager_stop (GsdUpdatesManager *manager)
         g_clear_object (&manager->priv->firmware);
         g_clear_object (&manager->priv->proxy_session);
         g_clear_object (&manager->priv->volume_monitor);
-        g_clear_object (&manager->priv->cancellable);
+        if (manager->priv->cancellable) {
+                g_cancellable_cancel (manager->priv->cancellable);
+                g_clear_object (&manager->priv->cancellable);
+        }
         g_clear_pointer (&manager->priv->introspection, g_dbus_node_info_unref);
         if (manager->priv->update_viewer_watcher_id != 0) {
                 g_bus_unwatch_name (manager->priv->update_viewer_watcher_id);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]