From 03d3f658e031473bfd51def9c890590659346b25 Mon Sep 17 00:00:00 2001 From: John Darrington Date: Fri, 1 Jul 2011 18:38:05 +0200 Subject: [PATCH] Avoid GtkCritical in recode dialog --- src/ui/gui/recode-dialog.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/ui/gui/recode-dialog.c b/src/ui/gui/recode-dialog.c index 55376644..5d97c156 100644 --- a/src/ui/gui/recode-dialog.c +++ b/src/ui/gui/recode-dialog.c @@ -364,7 +364,7 @@ refresh (PsppireDialog *dialog, struct recode_dialog *rd) gtk_widget_set_sensitive (rd->new_name_entry, FALSE); gtk_widget_set_sensitive (rd->new_label_entry, FALSE); - if ( rd->different ) + if ( rd->different && rd->varmap ) g_hash_table_remove_all (rd->varmap); gtk_list_store_clear (GTK_LIST_STORE (rd->value_map)); @@ -1068,7 +1068,8 @@ recode_dialog (PsppireDataWindow *de, gboolean diff) break; } - g_hash_table_destroy (rd.varmap); + if (rd.varmap) + g_hash_table_destroy (rd.varmap); gtk_list_store_clear (GTK_LIST_STORE (rd.value_map)); g_object_unref (rd.value_map); -- 2.30.2