[gnome-software/wip/ubuntu-3-20] apt: Fix cancellable double unref



commit 3ad58f1a5877e4af880bd8c45cf7699141709ba8
Author: Robert Ancell <robert ancell canonical com>
Date:   Tue May 23 21:54:47 2017 +1200

    apt: Fix cancellable double unref

 src/plugins/gs-plugin-apt.cc |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/plugins/gs-plugin-apt.cc b/src/plugins/gs-plugin-apt.cc
index 54c82cd..7ee1fa0 100644
--- a/src/plugins/gs-plugin-apt.cc
+++ b/src/plugins/gs-plugin-apt.cc
@@ -725,6 +725,7 @@ debconf_data_new (GCancellable *cancellable)
 static void
 debconf_data_free (DebconfData *data)
 {
+       g_clear_object (&data->cancellable);
        if (data->debconf_connection != NULL)
                g_socket_close (data->debconf_connection, NULL);
        g_clear_object (&data->debconf_connection);
@@ -770,7 +771,6 @@ transaction_data_new (GsPlugin *plugin, GCancellable *cancellable)
 static void
 transaction_data_free (TransactionData *data)
 {
-       g_clear_object (&data->cancellable);
        g_clear_object (&data->plugin);
        g_clear_object (&data->cancellable);
        g_free (data->result);


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