bu5hm4n pushed a commit to branch master. http://git.enlightenment.org/apps/extra.git/commit/?id=080f5c19972af35db7c6f54e420b7829c057e73b
commit 080f5c19972af35db7c6f54e420b7829c057e73b Author: Marcel Hollerbach <[email protected]> Date: Sun Mar 22 12:53:36 2020 +0100 extra: cleanup before preview_get this is needed in order to return the correct preview. --- src/lib/extra_api_helper.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/lib/extra_api_helper.c b/src/lib/extra_api_helper.c index c36fcb1..084a4f7 100644 --- a/src/lib/extra_api_helper.c +++ b/src/lib/extra_api_helper.c @@ -201,10 +201,16 @@ typedef struct { } Extra_Download_Job; static void -_download_job_free(Extra_Download_Job *job) +_download_clean_up(Extra_Download_Job *job) { if (job->clean_up) *job->clean_up = NULL; +} + +static void +_download_job_free(Extra_Download_Job *job) +{ + _download_clean_up(job); free(job->from); free(job->to); @@ -219,6 +225,8 @@ _download_complete_cb(void *data, const char *file EINA_UNUSED, int status EINA_ if (status != 200) ecore_file_remove(file); + _download_clean_up(job); + if (job->req.progress.done_cb) job->req.progress.done_cb(job->req.progress.data); --
