diff options
author | waker <wakeroid@gmail.com> | 2011-05-14 17:42:06 +0200 |
---|---|---|
committer | waker <wakeroid@gmail.com> | 2011-05-14 17:42:06 +0200 |
commit | 4b33d91796f40fec88218fe0693c9660bbda3d32 (patch) | |
tree | ded292cfcd99324c35e1af7c6874095ac9f631f5 | |
parent | f92aea56d89c1bfcb953a0fd57d07c08f65a53b1 (diff) |
minor gtkui memleak fix
-rw-r--r-- | plugins.c | 2 | ||||
-rw-r--r-- | plugins/gtkui/gtkui.c | 14 |
2 files changed, 12 insertions, 4 deletions
@@ -985,11 +985,9 @@ plug_unload_all (void) { trace ("stopped all plugins\n"); while (plugins) { plugin_t *next = plugins->next; -#ifndef ANDROID if (plugins->handle) { dlclose (plugins->handle); } -#endif free (plugins); plugins = next; } diff --git a/plugins/gtkui/gtkui.c b/plugins/gtkui/gtkui.c index ba84d0a7..62c0b8fd 100644 --- a/plugins/gtkui/gtkui.c +++ b/plugins/gtkui/gtkui.c @@ -1112,8 +1112,18 @@ gtkui_thread (void *ctx) { progress_destroy (); gtkui_hide_status_icon (); draw_free (); - gtk_widget_destroy (mainwin); - gtk_widget_destroy (searchwin); + if (theme_treeview) { + gtk_widget_destroy (theme_treeview); + theme_treeview = NULL; + } + if (mainwin) { + gtk_widget_destroy (mainwin); + mainwin = NULL; + } + if (searchwin) { + gtk_widget_destroy (searchwin); + searchwin = NULL; + } gdk_threads_leave (); } |