proper cleanup of efreet_desktop_command.

Efreet API is BRAIN NUTS, some stuff you're supposed to release (list)
and others are up to the callback to release.

Okay, I broke e17 trying to fix efreet tests. API is so inconsistent
that its own test was wrong. I'm reverting my change and fix the test,
but this is bad.



SVN revision: 41133
This commit is contained in:
Gustavo Sverzut Barbieri 2009-06-20 19:07:31 +00:00
parent 4eb71900a2
commit eac66d4e5a
2 changed files with 3 additions and 4 deletions

View File

@ -343,6 +343,7 @@ _cb_command(void *data, Efreet_Desktop *desktop __UNUSED__,
info->error++;
}
}
free(exec);
return NULL;
}

View File

@ -1226,8 +1226,7 @@ efreet_desktop_command_progress_get(Efreet_Desktop *desktop, Eina_List *files,
execs = efreet_desktop_command_build(command);
ret = efreet_desktop_command_execs_process(command, execs);
EINA_LIST_FREE(execs, exec)
free(exec);
eina_list_free(execs);
efreet_desktop_command_free(command);
}
@ -1788,8 +1787,7 @@ efreet_desktop_cb_download_complete(void *data, const char *file __UNUSED__,
execs = efreet_desktop_command_build(f->command);
/* TODO: Need to handle the return value from efreet_desktop_command_execs_process */
efreet_desktop_command_execs_process(f->command, execs);
EINA_LIST_FREE(execs, exec)
free(exec);
eina_list_free(execs);
efreet_desktop_command_free(f->command);
}
}