X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Fdialog-common.c;h=0aab294e12ef0b2a8ca937851f60533525847619;hb=82a1c1132557cfec30525068d873f97f56dbcab0;hp=fe2c7937ef45f539848783327f0332ca9a55dfd3;hpb=0bd0098aec2ee31d9460c8d4c1263d0b5ccc4324;p=pspp-builds.git diff --git a/src/ui/gui/dialog-common.c b/src/ui/gui/dialog-common.c index fe2c7937..0aab294e 100644 --- a/src/ui/gui/dialog-common.c +++ b/src/ui/gui/dialog-common.c @@ -193,16 +193,15 @@ homogeneous_types (GtkWidget *source, GtkWidget *dest) for (l = list; l ; l = l->next) { GtkTreePath *path = l->data; - GtkTreePath *fpath; - gint *idx; - const struct variable *v; + GtkTreePath *fpath = + gtk_tree_model_filter_convert_path_to_child_path (GTK_TREE_MODEL_FILTER (model), path); - fpath = gtk_tree_model_filter_convert_path_to_child_path (GTK_TREE_MODEL_FILTER (model), path); + gint *idx = gtk_tree_path_get_indices (fpath); - idx = gtk_tree_path_get_indices (fpath); + const struct variable *v = psppire_dict_get_variable (dict, idx[0]); - v = psppire_dict_get_variable (dict, idx[0]); + gtk_tree_path_free (fpath); if ( type != -1 ) { @@ -280,17 +279,14 @@ numeric_only (GtkWidget *source, GtkWidget *dest) for (l = list; l ; l = l->next) { GtkTreePath *path = l->data; - GtkTreePath *fpath; - gint *idx; - - const struct variable *v; - - fpath = gtk_tree_model_filter_convert_path_to_child_path + GtkTreePath *fpath = gtk_tree_model_filter_convert_path_to_child_path (GTK_TREE_MODEL_FILTER (model), path); - idx = gtk_tree_path_get_indices (fpath); + gint *idx = gtk_tree_path_get_indices (fpath); + + const struct variable *v = psppire_dict_get_variable (dict, idx[0]); - v = psppire_dict_get_variable (dict, idx[0]); + gtk_tree_path_free (fpath); if ( var_is_alpha (v)) {