Fixed multiple memory leaks
o9000 mrovi9000@gmail.com
3 files changed,
8 insertions(+),
0 deletions(-)
M
src/execplugin/execplugin.c
→
src/execplugin/execplugin.c
@@ -59,6 +59,9 @@ if (execp->frontend) {
// This is a frontend element execp->backend->instances = g_list_remove_all(execp->backend->instances, execp); free_and_null(execp->frontend); + remove_area(&execp->area); + free_area(&execp->area); + free_and_null(execp); } else { // This is a backend element stop_timeout(execp->backend->timer);
M
src/launcher/icon-theme-common.c
→
src/launcher/icon-theme-common.c
@@ -305,6 +305,7 @@ void free_themes(IconThemeWrapper *wrapper)
{ if (!wrapper) return; + free(wrapper->icon_theme_name); for (GSList *l = wrapper->themes; l; l = l->next) { IconTheme *theme = (IconTheme *)l->data; free_icon_theme(theme);
M
src/launcher/launcher.c
→
src/launcher/launcher.c
@@ -452,7 +452,11 @@ {
DesktopEntry entry; if (read_desktop_file(launcherIcon->config_path, &entry) && entry.exec) { schedule_redraw(&launcherIcon->area); + if (launcherIcon->cmd) + free(launcherIcon->cmd); launcherIcon->cmd = strdup(entry.exec); + if (launcherIcon->icon_name) + free(launcherIcon->icon_name); launcherIcon->icon_name = entry.icon ? strdup(entry.icon) : strdup(DEFAULT_ICON); if (entry.name) { if (entry.generic_name) {