[gnome-control-center/gnome-3-30] region: Fix double-free when closing the input chooser dialog



commit 0c1c5570772e948adb6abb5c348f356ecba42383
Author: Andrea Azzarone <andrea azzarone canonical com>
Date:   Tue Oct 9 11:58:08 2018 +0100

    region: Fix double-free when closing the input chooser dialog
    
    Fixes: GNOME/gnome-control-center#225

 panels/region/cc-input-chooser.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/panels/region/cc-input-chooser.c b/panels/region/cc-input-chooser.c
index 674662052..5c2ee8383 100644
--- a/panels/region/cc-input-chooser.c
+++ b/panels/region/cc-input-chooser.c
@@ -953,7 +953,7 @@ get_locale_infos (GtkWidget *chooser)
   info->name = g_strdup (C_("Input Source", "Other"));
   info->unaccented_name = g_strdup ("");
   info->untranslated_name = g_strdup ("");
-  g_hash_table_replace (priv->locales, info->id, info);
+  g_hash_table_replace (priv->locales, g_strdup (info->id), info);
 
   info->layout_rows_by_id = g_hash_table_new_full (g_str_hash, g_str_equal,
                                                    NULL, g_object_unref);


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