[gnome-software/gnome-3-26] packagekit history: Fix a leak on the error path



commit 46ef0cd6c513f752f09ab64e458fffa765865848
Author: Kalev Lember <klember redhat com>
Date:   Wed Jan 31 21:57:25 2018 +0100

    packagekit history: Fix a leak on the error path

 plugins/packagekit/gs-plugin-packagekit-history.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/plugins/packagekit/gs-plugin-packagekit-history.c 
b/plugins/packagekit/gs-plugin-packagekit-history.c
index 9f04140b..37f3b987 100644
--- a/plugins/packagekit/gs-plugin-packagekit-history.c
+++ b/plugins/packagekit/gs-plugin-packagekit-history.c
@@ -122,13 +122,13 @@ gs_plugin_packagekit_refine (GsPlugin *plugin,
 {
        GsPluginData *priv = gs_plugin_get_data (plugin);
        gboolean ret;
-       GError *error_local = NULL;
        guint j;
        GsApp *app;
        guint i = 0;
        GVariantIter iter;
        GVariant *value;
        g_autofree const gchar **package_names = NULL;
+       g_autoptr(GError) error_local = NULL;
        g_autoptr(GVariant) result = NULL;
        g_autoptr(GVariant) tuple = NULL;
 


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