Subject: [E-devel] [ecore_file] Check a return value of
ecore_con_url_get()
_ecore_file_download_curl() does not check return value of even if
ecore_con_url_get(), it can be failed.
I add a simple error checking.
Please review this patch.
git-svn-id: http://svn.enlightenment.org/svn/e/trunk/ecore@64795
7cbeb6ba-43b4-40fd-8cce-
4c39aea84d33
job->progress_cb = progress_cb;
_job_list = eina_list_append(_job_list, job);
- ecore_con_url_get(job->url_con);
+ if (!ecore_con_url_get(job->url_con))
+ {
+ ecore_con_url_free(job->url_con);
+ _job_list = eina_list_remove(_job_list, job);
+ fclose(job->file);
+ free(job->dst);
+ free(job);
+ return NULL;
+ }
return job;
}