[PATCH 2/5] Unref the two GtkTreeStore instances when destroying the divelist
Lubomir I. Ivanov
neolit123 at gmail.com
Wed Feb 20 17:07:19 PST 2013
From: "Lubomir I. Ivanov" <neolit123 at gmail.com>
Even if these exists for the heap lifespan, we can call:
g_object_unref(dive_list.treemodel);
g_object_unref(dive_list.listmodel);
in divelist.c:dive_list_destroy()
Signed-off-by: Lubomir I. Ivanov <neolit123 at gmail.com>
---
divelist.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/divelist.c b/divelist.c
index 75d525e..85fb535 100644
--- a/divelist.c
+++ b/divelist.c
@@ -2628,6 +2628,8 @@ GtkWidget *dive_list_create(void)
void dive_list_destroy(void)
{
gtk_widget_destroy(dive_list.tree_view);
+ g_object_unref(dive_list.treemodel);
+ g_object_unref(dive_list.listmodel);
}
void mark_divelist_changed(int changed)
--
1.7.11.msysgit.0
More information about the subsurface
mailing list