Hi all:

    trunk/ext/fileinfo/libmagic/softmagic.c seems to be a third-party
source, I was wondering can I directly modify it?

    it can't be compiled with -Wall -Werror, with a lots of warnings..

thanks

2011/8/9 <larue...@baidu.com>

>
>
> -------- Original Message --------  Subject: [PHP-CVS] svn: /php/php-src/
> branches/PHP_5_3/ext/fileinfo/libmagic/softmagic.c
> branches/PHP_5_4/ext/fileinfo/libmagic/softmagic.c
> trunk/ext/fileinfo/libmagic/softmagic.c  Date: Tue, 9 Aug 2011 00:57:46
> +0800  From: Xinchen Hui <larue...@php.net> <larue...@php.net>  To:
> php-cvs@lists.php.net <php-cvs@lists.php.net> <php-cvs@lists.php.net>
>
> laruence                                 Mon, 08 Aug 2011 16:57:46 +0000
>
> Revision: http://svn.php.net/viewvc?view=revision&revision=314565
>
> Log:
> Remove unnecessary(no sense) memset and making the static analyzer silent
>
> Changed paths:
>     U   php/php-src/branches/PHP_5_3/ext/fileinfo/libmagic/softmagic.c
>     U   php/php-src/branches/PHP_5_4/ext/fileinfo/libmagic/softmagic.c
>     U   php/php-src/trunk/ext/fileinfo/libmagic/softmagic.c
>
> Modified: php/php-src/branches/PHP_5_3/ext/fileinfo/libmagic/softmagic.c
> ===================================================================
> --- php/php-src/branches/PHP_5_3/ext/fileinfo/libmagic/softmagic.c      
> 2011-08-08 16:49:43 UTC (rev 314564)
> +++ php/php-src/branches/PHP_5_3/ext/fileinfo/libmagic/softmagic.c      
> 2011-08-08 16:57:46 UTC (rev 314565)
> @@ -1652,7 +1652,6 @@
>                 char *t;
>
>                 t = (char *) safe_emalloc(Z_STRLEN_P(pattern), 2, 5);
> -               memset(t, '\0', sizeof(t));
>
>                 t[j++] = '~';
>
>
> Modified: php/php-src/branches/PHP_5_4/ext/fileinfo/libmagic/softmagic.c
> ===================================================================
> --- php/php-src/branches/PHP_5_4/ext/fileinfo/libmagic/softmagic.c      
> 2011-08-08 16:49:43 UTC (rev 314564)
> +++ php/php-src/branches/PHP_5_4/ext/fileinfo/libmagic/softmagic.c      
> 2011-08-08 16:57:46 UTC (rev 314565)
> @@ -1652,7 +1652,6 @@
>                 char *t;
>
>                 t = (char *) safe_emalloc(Z_STRLEN_P(pattern), 2, 5);
> -               memset(t, '\0', sizeof(t));
>
>                 t[j++] = '~';
>
>
> Modified: php/php-src/trunk/ext/fileinfo/libmagic/softmagic.c
> ===================================================================
> --- php/php-src/trunk/ext/fileinfo/libmagic/softmagic.c 2011-08-08 16:49:43 
> UTC (rev 314564)
> +++ php/php-src/trunk/ext/fileinfo/libmagic/softmagic.c 2011-08-08 16:57:46 
> UTC (rev 314565)
> @@ -1652,7 +1652,6 @@
>                 char *t;
>
>                 t = (char *) safe_emalloc(Z_STRLEN_P(pattern), 2, 5);
> -               memset(t, '\0', sizeof(t));
>
>                 t[j++] = '~';
>
>
>
>


-- 
Laruence  Xinchen Hui
http://www.laruence.com/

Reply via email to