]> Dogcows Code - chaz/tint2/blobdiff - src/launcher/launcher.c
Fix possible double free in launcher
[chaz/tint2] / src / launcher / launcher.c
index 2dba4fda40be6a34433dfdc042e90dccb4a91f03..ab4ca29d67526e62192b9d40bf87a9b3627577dc 100644 (file)
@@ -111,15 +111,11 @@ void cleanup_launcher()
                Panel *panel = &panel1[i];
                Launcher *launcher = &panel->launcher;          
                cleanup_launcher_theme(launcher);
-               
-               GSList *l;
-               for (l = launcher->list_apps; l ; l = l->next) {
-                       free(l->data);
-               }
-               g_slist_free(launcher->list_apps);
-               launcher->list_apps = NULL;
        }
-       g_free(icon_theme_name);
+       g_slist_free_full(panel_config.launcher.list_apps, free);
+       panel_config.launcher.list_apps = NULL;
+       free(icon_theme_name);
+       icon_theme_name = 0;
        launcher_enabled = 0;
 }
 
This page took 0.020796 seconds and 4 git commands to generate.