On Wed, 9 Nov 2011 09:50:11 +0900
Bluezery <ohpo...@gmail.com> wrote:

> Hi,
> 
> I add "ecore_file_remove()" for removing a NULL file opened by
> "fopen(dst, "wb")".
> 
> Please review below.
> 
> 
> 
> Index: src/lib/ecore_file/ecore_file_download.c
> ===================================================================
> --- src/lib/ecore_file/ecore_file_download.c  (리비전 64937)
> +++ src/lib/ecore_file/ecore_file_download.c  (작업 사본)
> @@ -105,14 +105,14 @@ _ecore_file_download(const char *url,
> 
>     if (!ecore_file_is_dir(dir))
>       {
> -        EINA_LOG_ERR("%s is not a directory", dir);
> +        ERR("%s is not a directory", dir);
>          free(dir);
>          return EINA_FALSE;
>       }
>     free(dir);
>     if (ecore_file_exists(dst))
>       {
> -        EINA_LOG_ERR("%s already exists", dst);
> +        WRN("%s already exists", dst);
>          return EINA_FALSE;
>       }
> 
> @@ -140,7 +140,7 @@ _ecore_file_download(const char *url,
>            return EINA_TRUE;
>          else
>            {
> -             EINA_LOG_ERR("no job returned\n");
> +             ERR("no job returned\n");
>               return EINA_FALSE;
>            }
>          return job ? EINA_TRUE : EINA_FALSE;
> @@ -374,6 +374,7 @@ _ecore_file_download_curl(const char *ur
>          ecore_con_url_free(job->url_con);
>          _job_list = eina_list_remove(_job_list, job);
>          fclose(job->file);
> +        ecore_file_remove(job->dst);
>          free(job->dst);
>          free(job);
>          return NULL;
in

-- 
Mike Blumenkrantz
Zentific: Doctor recommended, mother approved.

------------------------------------------------------------------------------
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to