[gnome-initial-setup/gnome-3-10] goa: Prevent a use-after-free



commit 48302b7796e7016dc563f3d6366982f073b27ebe
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Sat Nov 9 11:43:48 2013 -0500

    goa: Prevent a use-after-free
    
    If the user dismisses the dialog, we'll get an error and free it,
    but forget to set it to NULL, and segfault.

 gnome-initial-setup/pages/goa/gis-goa-page.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gnome-initial-setup/pages/goa/gis-goa-page.c b/gnome-initial-setup/pages/goa/gis-goa-page.c
index 85b8ff5..3228159 100644
--- a/gnome-initial-setup/pages/goa/gis-goa-page.c
+++ b/gnome-initial-setup/pages/goa/gis-goa-page.c
@@ -106,7 +106,7 @@ on_have_providers (GObject       *source,
           gtk_dialog_run (GTK_DIALOG (dialog));
           gtk_widget_destroy (dialog);
         }
-      g_error_free (error);
+      g_clear_error (&error);
     }
 
   g_list_free_full (providers, g_object_unref);


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