From 1ec985a141ebae150a3d576a70861d4531b431cf Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Sun, 24 Oct 2004 05:49:14 +0000 Subject: [PATCH] Don't destroy the lookup map if it is NULL. 2004-10-24 Matthias Clasen * glib/gkeyfile.c (g_key_file_remove_group_node): Don't destroy the lookup map if it is NULL. 20 --- ChangeLog | 5 +++++ ChangeLog.pre-2-10 | 5 +++++ ChangeLog.pre-2-12 | 5 +++++ ChangeLog.pre-2-6 | 5 +++++ ChangeLog.pre-2-8 | 5 +++++ glib/gkeyfile.c | 7 +++++-- 6 files changed, 30 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index b6cde975..519acc65 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2004-10-24 Matthias Clasen + + * glib/gkeyfile.c (g_key_file_remove_group_node): Don't + destroy the lookup map if it is NULL. + 2004-10-23 Matthias Clasen * glib/gasyncqueue.c, glib/gatomic.c, glib/gdate.c, diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index b6cde975..519acc65 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,8 @@ +2004-10-24 Matthias Clasen + + * glib/gkeyfile.c (g_key_file_remove_group_node): Don't + destroy the lookup map if it is NULL. + 2004-10-23 Matthias Clasen * glib/gasyncqueue.c, glib/gatomic.c, glib/gdate.c, diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index b6cde975..519acc65 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,8 @@ +2004-10-24 Matthias Clasen + + * glib/gkeyfile.c (g_key_file_remove_group_node): Don't + destroy the lookup map if it is NULL. + 2004-10-23 Matthias Clasen * glib/gasyncqueue.c, glib/gatomic.c, glib/gdate.c, diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index b6cde975..519acc65 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,8 @@ +2004-10-24 Matthias Clasen + + * glib/gkeyfile.c (g_key_file_remove_group_node): Don't + destroy the lookup map if it is NULL. + 2004-10-23 Matthias Clasen * glib/gasyncqueue.c, glib/gatomic.c, glib/gdate.c, diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index b6cde975..519acc65 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,8 @@ +2004-10-24 Matthias Clasen + + * glib/gkeyfile.c (g_key_file_remove_group_node): Don't + destroy the lookup map if it is NULL. + 2004-10-23 Matthias Clasen * glib/gasyncqueue.c, glib/gatomic.c, glib/gdate.c, diff --git a/glib/gkeyfile.c b/glib/gkeyfile.c index 896a168c..0d2a4d46 100644 --- a/glib/gkeyfile.c +++ b/glib/gkeyfile.c @@ -2168,8 +2168,11 @@ g_key_file_remove_group_node (GKeyFile *key_file, g_list_free (group->key_value_pairs); group->key_value_pairs = NULL; - g_hash_table_destroy (group->lookup_map); - group->lookup_map = NULL; + if (group->lookup_map) + { + g_hash_table_destroy (group->lookup_map); + group->lookup_map = NULL; + } g_free ((gchar *) group->name); g_free (group); -- 2.34.1