diff options
Diffstat (limited to 'widgets')
-rw-r--r-- | widgets/table/e-table-header-item.c | 8 | ||||
-rw-r--r-- | widgets/table/e-table-state.c | 2 | ||||
-rw-r--r-- | widgets/table/e-table.c | 8 |
3 files changed, 13 insertions, 5 deletions
diff --git a/widgets/table/e-table-header-item.c b/widgets/table/e-table-header-item.c index 932846b6a0..2c13ef3dcc 100644 --- a/widgets/table/e-table-header-item.c +++ b/widgets/table/e-table-header-item.c @@ -85,12 +85,18 @@ ethi_destroy (GtkObject *object){ ethi_drop_table_header (ethi); - if (ethi->sort_info){ + if (ethi->dnd_code) { + g_free (ethi->dnd_code); + ethi->dnd_code = NULL; + } + + if (ethi->sort_info) { if (ethi->sort_info_changed_id) gtk_signal_disconnect (GTK_OBJECT(ethi->sort_info), ethi->sort_info_changed_id); if (ethi->group_info_changed_id) gtk_signal_disconnect (GTK_OBJECT(ethi->sort_info), ethi->group_info_changed_id); gtk_object_unref (GTK_OBJECT(ethi->sort_info)); + ethi->sort_info = NULL; } if (GTK_OBJECT_CLASS (ethi_parent_class)->destroy) diff --git a/widgets/table/e-table-state.c b/widgets/table/e-table-state.c index 9361f4f940..36c7293267 100644 --- a/widgets/table/e-table-state.c +++ b/widgets/table/e-table-state.c @@ -117,6 +117,7 @@ e_table_state_save_to_file (ETableState *state, doc = xmlNewDoc("1.0"); xmlDocSetRootElement(doc, e_table_state_save_to_node(state, NULL)); xmlSaveFile(filename, doc); + xmlFreeDoc(doc); } char * @@ -130,6 +131,7 @@ e_table_state_save_to_string (ETableState *state) doc = xmlNewDoc(NULL); xmlDocSetRootElement(doc, e_table_state_save_to_node(state, NULL)); xmlDocDumpMemory(doc, &string, &length); + xmlFreeDoc(doc); ret_val = g_strdup(string); xmlFree(string); diff --git a/widgets/table/e-table.c b/widgets/table/e-table.c index e55e9ee010..271884ea14 100644 --- a/widgets/table/e-table.c +++ b/widgets/table/e-table.c @@ -777,7 +777,7 @@ void e_table_set_state (ETable *e_table if (state->col_count > 0) e_table_set_state_object(e_table, state); - gtk_object_sink(GTK_OBJECT(state)); + gtk_object_unref(GTK_OBJECT(state)); } void e_table_load_state (ETable *e_table, @@ -795,7 +795,7 @@ void e_table_load_state (ETable *e_table if (state->col_count > 0) e_table_set_state_object(e_table, state); - gtk_object_sink(GTK_OBJECT(state)); + gtk_object_unref(GTK_OBJECT(state)); } ETableState * @@ -834,7 +834,7 @@ gchar *e_table_get_state (ETable *e_table state = e_table_get_state_object(e_table); string = e_table_state_save_to_string(state); - gtk_object_sink(GTK_OBJECT(state)); + gtk_object_unref(GTK_OBJECT(state)); return string; } @@ -845,7 +845,7 @@ void e_table_save_state (ETable *e_table state = e_table_get_state_object(e_table); e_table_state_save_to_file(state, filename); - gtk_object_sink(GTK_OBJECT(state)); + gtk_object_unref(GTK_OBJECT(state)); } static void |