updated on Thu Jan 12 04:00:44 UTC 2012
[aur-mirror.git] / gtk3-ubuntu / fix_crash_treeview.patch
blob12c6372f11dfed780e23b67a5c75d69346503bfc
1 From 456b19a35adbdc4b098e6da020c3a87cb62ae7f4 Mon Sep 17 00:00:00 2001
2 From: Benjamin Otte <otte@redhat.com>
3 Date: Thu, 10 Nov 2011 15:52:44 +0000
4 Subject: a11y: Fix gcc warning
6 ---
7 diff --git a/gtk/a11y/gtktreeviewaccessible.c b/gtk/a11y/gtktreeviewaccessible.c
8 index 663bb51..b2ca9ba 100644
9 --- a/gtk/a11y/gtktreeviewaccessible.c
10 +++ b/gtk/a11y/gtktreeviewaccessible.c
11 @@ -238,7 +238,7 @@ gtk_tree_view_accessible_initialize (AtkObject *obj,
12 accessible->n_children_deleted = 0;
14 accessible->cell_info_by_index = g_hash_table_new_full (g_int_hash,
15 - g_int_equal, NULL, cell_info_free);
16 + g_int_equal, NULL, (GDestroyNotify) cell_info_free);
18 widget = GTK_WIDGET (data);
19 tree_view = GTK_TREE_VIEW (widget);
21 cgit v0.9.0.2
22 From b25621173734ad1c9cee83802f7ac32ab7df20e7 Mon Sep 17 00:00:00 2001
23 From: Guillaume Desmottes <guillaume.desmottes@collabora.co.uk>
24 Date: Wed, 09 Nov 2011 13:32:32 +0000
25 Subject: gtktreeviewaccessible: use a value_destroy_func with the cell_info_by_index hash
27 This ensures that we don't leak any GtkTreeViewAccessibleCellInfo when
28 re-inserting a new one with the same key.
30 https://bugzilla.gnome.org/show_bug.cgi?id=663694
31 ---
32 diff --git a/gtk/a11y/gtktreeviewaccessible.c b/gtk/a11y/gtktreeviewaccessible.c
33 index 046e253..4ad323c 100644
34 --- a/gtk/a11y/gtktreeviewaccessible.c
35 +++ b/gtk/a11y/gtktreeviewaccessible.c
36 @@ -237,7 +237,8 @@ gtk_tree_view_accessible_initialize (AtkObject *obj,
37 accessible->idle_expand_path = NULL;
38 accessible->n_children_deleted = 0;
40 - accessible->cell_info_by_index = g_hash_table_new (g_int_hash, g_int_equal);
41 + accessible->cell_info_by_index = g_hash_table_new_full (g_int_hash,
42 + g_int_equal, NULL, cell_info_free);
44 widget = GTK_WIDGET (data);
45 tree_view = GTK_TREE_VIEW (widget);
46 @@ -2845,7 +2846,6 @@ garbage_collect_cell_data (gpointer data)
48 if (!cell_info->in_use)
50 - cell_info_free (cell_info);
51 g_hash_table_iter_remove (&iter);
55 cgit v0.9.0.2