changeset 650:980d651da2fc trunk

[svn] Actually use the cleanup hooks on general & visualization plugins.
author chainsaw
date Sun, 19 Feb 2006 15:35:37 -0800
parents e43b04a4e599
children c1645fb045a7
files audacious/pluginenum.c
diffstat 1 files changed, 12 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/audacious/pluginenum.c	Sun Feb 19 15:18:05 2006 -0800
+++ b/audacious/pluginenum.c	Sun Feb 19 15:35:37 2006 -0800
@@ -417,6 +417,12 @@
 
     for (node = get_general_list(); node; node = g_list_next(node)) {
         gp = GENERAL_PLUGIN(node->data);
+        if (gp && gp->cleanup) {
+            gp->cleanup();
+            GDK_THREADS_LEAVE();
+            while (g_main_iteration(FALSE));
+            GDK_THREADS_ENTER();
+        }
         g_module_close(gp->handle);
     }
 
@@ -437,6 +443,12 @@
 
     for (node = get_vis_list(); node; node = g_list_next(node)) {
         vp = VIS_PLUGIN(node->data);
+        if (vp && vp->cleanup) {
+            vp->cleanup();
+            GDK_THREADS_LEAVE();
+            while (g_main_iteration(FALSE));
+            GDK_THREADS_ENTER();
+        }
         g_module_close(vp->handle);
     }