cvs: pecl /zip package.xml /zip/lib zip_dirent.c

From: Date: Sun, 17 Dec 2006 13:57:10 +0000
Subject: cvs: pecl /zip package.xml /zip/lib zip_dirent.c
Groups: php.pecl.cvs 
Request: Send a blank email to pecl-cvs+get-6800@lists.php.net to get a copy of this message
pajoye Sun Dec 17 13:57:10 2006 UTC Modified files: /pecl/zip/lib zip_dirent.c /pecl/zip package.xml Log: - sync with php-src - fix TS issue in localtime, use php_localtime_r (Ron Korving, Ilia) http://cvs.php.net/viewvc.cgi/pecl/zip/lib/zip_dirent.c?r1=1.4&r2=1.5&diff_format=u Index: pecl/zip/lib/zip_dirent.c diff -u pecl/zip/lib/zip_dirent.c:1.4 pecl/zip/lib/zip_dirent.c:1.5 --- pecl/zip/lib/zip_dirent.c:1.4 Thu May 18 15:12:55 2006 +++ pecl/zip/lib/zip_dirent.c Sun Dec 17 13:57:10 2006 @@ -33,8 +33,7 @@ IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - - +#include "main/php_reentrancy.h" #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -391,11 +390,11 @@ static time_t _zip_d2u_time(int dtime, int ddate) { - struct tm *tm; + struct tm *tm, tmbuf; time_t now; now = time(NULL); - tm = localtime(&now); + tm = php_localtime_r(&now, &tmbuf); tm->tm_year = ((ddate>>9)&127) + 1980 - 1900; tm->tm_mon = ((ddate>>5)&15) - 1; @@ -520,9 +519,9 @@ static void _zip_u2d_time(time_t time, unsigned short *dtime, unsigned short *ddate) { - struct tm *tm; + struct tm *tm, tmbuf; - tm = localtime(&time); + tm = php_localtime_r(&time, &tmbuf); *ddate = ((tm->tm_year+1900-1980)<<9) + ((tm->tm_mon+1)<<5) + tm->tm_mday; *dtime = ((tm->tm_hour)<<11) + ((tm->tm_min)<<5) http://cvs.php.net/viewvc.cgi/pecl/zip/package.xml?r1=1.71&r2=1.72&diff_format=u Index: pecl/zip/package.xml diff -u pecl/zip/package.xml:1.71 pecl/zip/package.xml:1.72 --- pecl/zip/package.xml:1.71 Sat Dec 2 04:59:19 2006 +++ pecl/zip/package.xml Sun Dec 17 13:57:10 2006 @@ -10,9 +10,9 @@ <email>pajoye@php.net</email> <active>yes</active> </lead> - <date>2006-12-02</date> + <date>2006-12-17</date> <version> - <release>1.8.2</release> + <release>1.8.3</release> <api>2.0.0</api> </version> <stability> @@ -20,7 +20,8 @@ <api>stable</api> </stability> <license uri="http://www.php.net/license">PHP License</license> -<notes>- restore compatibility with php 5.1.0 to 5.1.2 (other versions are not affected)</notes> +<notes>- Fixed threadsafe issue with localtime function, it uses now the + php php_localtime_r (Ron Korving, Ilia)</notes> <contents> <dir name="/"> <file name="config.m4" role="src"/> @@ -158,6 +159,19 @@ <providesextension>zip</providesextension> <extsrcrelease/> <changelog> +<release> + <date>2006-12-02</date> + <version> + <release>1.8.2</release> + <api>2.0.0</api> + </version> + <stability> + <release>stable</release> + <api>stable</api> + </stability> + <license uri="http://www.php.net/license">PHP License</license> +<notes>- restore compatibility with php 5.1.0 to 5.1.2 (other versions are not affected)</notes> +</release> <release> <date>2006-11-28</date> <version>

« previous php.pecl.cvs (#6800) next »