[PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/ext/date/tests/bug51223.phpt trunk/ext/date/tests/bug51223.phpt
pajoye Wed, 07 Dec 2011 08:33:41 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320561 Log: - set TZ Changed paths: U php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt U php/php-src/trunk/ext/date/tests/bug51223.phpt Modified: php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt === --- php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt 2011-12-07 08:00:32 UTC (rev 320560) +++ php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt 2011-12-07 08:33:41 UTC (rev 320561) @@ -1,5 +1,7 @@ --TEST-- Bug #52113: Seg fault while creating (by unserialization) DatePeriod +--INI-- +date.timezone=UTC --FILE-- ?php $start = new DateTime('2003-01-02 08:00:00'); Modified: php/php-src/trunk/ext/date/tests/bug51223.phpt === --- php/php-src/trunk/ext/date/tests/bug51223.phpt 2011-12-07 08:00:32 UTC (rev 320560) +++ php/php-src/trunk/ext/date/tests/bug51223.phpt 2011-12-07 08:33:41 UTC (rev 320561) @@ -1,5 +1,7 @@ --TEST-- Bug #52113: Seg fault while creating (by unserialization) DatePeriod +--INI-- +date.timezone=UTC --FILE-- ?php $start = new DateTime('2003-01-02 08:00:00'); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/ext/date/tests/bug51223.phpt branches/PHP_5_4/ext/date/tests/bug52113.phpt trunk/ext/date/tests/bug51223.phpt trunk/ext/date/tests/bug52113.phpt trunk/ext
pajoye Wed, 07 Dec 2011 08:37:48 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320562 Log: - rename to correct bug # Changed paths: D php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt A + php/php-src/branches/PHP_5_4/ext/date/tests/bug52113.phpt (from php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt:r320561) D php/php-src/trunk/ext/date/tests/bug51223.phpt A + php/php-src/trunk/ext/date/tests/bug52113.phpt (from php/php-src/trunk/ext/date/tests/bug51223.phpt:r320561) U php/php-src/trunk/ext/date/tests/date_default_timezone_set-1.phpt Deleted: php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt === --- php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt 2011-12-07 08:33:41 UTC (rev 320561) +++ php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt 2011-12-07 08:37:48 UTC (rev 320562) @@ -1,102 +0,0 @@ ---TEST-- -Bug #52113: Seg fault while creating (by unserialization) DatePeriod ---INI-- -date.timezone=UTC ---FILE-- -?php -$start = new DateTime('2003-01-02 08:00:00'); -$end = new DateTime('2003-01-02 12:00:00'); -$diff = $start-diff($end); -$p = new DatePeriod($start, $diff, 2); -$diff_s = serialize($diff); -var_dump($diff, $diff_s); -var_export($diff); - -$diff_un = unserialize($diff_s); -$p = new DatePeriod($start, $diff_un, 2); -var_dump($diff_un, $p); - -$unser = DateInterval::__set_state(array( - 'y' = 7, - 'm' = 6, - 'd' = 5, - 'h' = 4, - 'i' = 3, - 's' = 2, - 'invert' = 1, - 'days' = 2400, -)); - -$p = new DatePeriod($start, $diff_un, 2); -var_dump($unser, $p); - -? ---EXPECT-- -object(DateInterval)#3 (8) { - [y]= - int(0) - [m]= - int(0) - [d]= - int(0) - [h]= - int(4) - [i]= - int(0) - [s]= - int(0) - [invert]= - int(0) - [days]= - int(0) -} -string(128) O:12:DateInterval:8:{s:1:y;i:0;s:1:m;i:0;s:1:d;i:0;s:1:h;i:4;s:1:i;i:0;s:1:s;i:0;s:6:invert;i:0;s:4:days;i:0;} -DateInterval::__set_state(array( - 'y' = 0, - 'm' = 0, - 'd' = 0, - 'h' = 4, - 'i' = 0, - 's' = 0, - 'invert' = 0, - 'days' = 0, -))object(DateInterval)#5 (8) { - [y]= - int(0) - [m]= - int(0) - [d]= - int(0) - [h]= - int(4) - [i]= - int(0) - [s]= - int(0) - [invert]= - int(0) - [days]= - int(0) -} -object(DatePeriod)#6 (0) { -} -object(DateInterval)#4 (8) { - [y]= - int(7) - [m]= - int(6) - [d]= - int(5) - [h]= - int(4) - [i]= - int(3) - [s]= - int(2) - [invert]= - int(1) - [days]= - int(2400) -} -object(DatePeriod)#7 (0) { -} Copied: php/php-src/branches/PHP_5_4/ext/date/tests/bug52113.phpt (from rev 320561, php/php-src/branches/PHP_5_4/ext/date/tests/bug51223.phpt) === --- php/php-src/branches/PHP_5_4/ext/date/tests/bug52113.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/date/tests/bug52113.phpt 2011-12-07 08:37:48 UTC (rev 320562) @@ -0,0 +1,102 @@ +--TEST-- +Bug #52113: Seg fault while creating (by unserialization) DatePeriod +--INI-- +date.timezone=UTC +--FILE-- +?php +$start = new DateTime('2003-01-02 08:00:00'); +$end = new DateTime('2003-01-02 12:00:00'); +$diff = $start-diff($end); +$p = new DatePeriod($start, $diff, 2); +$diff_s = serialize($diff); +var_dump($diff, $diff_s); +var_export($diff); + +$diff_un = unserialize($diff_s); +$p = new DatePeriod($start, $diff_un, 2); +var_dump($diff_un, $p); + +$unser = DateInterval::__set_state(array( + 'y' = 7, + 'm' = 6, + 'd' = 5, + 'h' = 4, + 'i' = 3, + 's' = 2, + 'invert' = 1, + 'days' = 2400, +)); + +$p = new DatePeriod($start, $diff_un, 2); +var_dump($unser, $p); + +? +--EXPECT-- +object(DateInterval)#3 (8) { + [y]= + int(0) + [m]= + int(0) + [d]= + int(0) + [h]= + int(4) + [i]= + int(0) + [s]= + int(0) + [invert]= + int(0) + [days]= + int(0) +} +string(128) O:12:DateInterval:8:{s:1:y;i:0;s:1:m;i:0;s:1:d;i:0;s:1:h;i:4;s:1:i;i:0;s:1:s;i:0;s:6:invert;i:0;s:4:days;i:0;} +DateInterval::__set_state(array( + 'y' = 0, + 'm' = 0, + 'd' = 0, + 'h' = 4, + 'i' = 0, + 's' = 0, + 'invert' = 0, + 'days' = 0, +))object(DateInterval)#5 (8) { + [y]= + int(0) + [m]= + int(0) + [d]= + int(0) + [h]= + int(4) + [i]= + int(0) + [s]= + int(0) + [invert]= + int(0) + [days]= + int(0) +} +object(DatePeriod)#6 (0) { +} +object(DateInterval)#4 (8) { + [y]= + int(7) + [m]= + int(6) + [d]= + int(5) + [h]= + int(4) + [i]= + int(3) + [s]= + int(2) + [invert]= + int(1) + [days]= + int(2400) +} +object(DatePeriod)#7 (0) { +} Deleted: php/php-src/trunk/ext/date/tests/bug51223.phpt === --- php/php-src/trunk/ext/date/tests/bug51223.phpt 2011-12-07 08:33:41 UTC (rev 320561) +++ php/php-src/trunk/ext/date/tests/bug51223.phpt 2011-12-07 08:37:48 UTC (rev 320562) @@ -1,102 +0,0 @@ ---TEST-- -Bug #52113: Seg fault while
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/date/lib/interval.c branches/PHP_5_4/ext/date/lib/interval.c trunk/ext/date/lib/interval.c
pajoye Wed, 07 Dec 2011 08:39:43 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320563 Log: - fix warning and fix buggy behavior of timelib_diff due to bad assumption of floor signature (fixes almost date_diff tests too) Changed paths: U php/php-src/branches/PHP_5_3/ext/date/lib/interval.c U php/php-src/branches/PHP_5_4/ext/date/lib/interval.c U php/php-src/trunk/ext/date/lib/interval.c Modified: php/php-src/branches/PHP_5_3/ext/date/lib/interval.c === --- php/php-src/branches/PHP_5_3/ext/date/lib/interval.c2011-12-07 08:37:48 UTC (rev 320562) +++ php/php-src/branches/PHP_5_3/ext/date/lib/interval.c2011-12-07 08:39:43 UTC (rev 320563) @@ -19,6 +19,7 @@ /* $Id$ */ #include timelib.h +#include math.h timelib_rel_time *timelib_diff(timelib_time *one, timelib_time *two) { Modified: php/php-src/branches/PHP_5_4/ext/date/lib/interval.c === --- php/php-src/branches/PHP_5_4/ext/date/lib/interval.c2011-12-07 08:37:48 UTC (rev 320562) +++ php/php-src/branches/PHP_5_4/ext/date/lib/interval.c2011-12-07 08:39:43 UTC (rev 320563) @@ -19,6 +19,7 @@ /* $Id$ */ #include timelib.h +#include math.h timelib_rel_time *timelib_diff(timelib_time *one, timelib_time *two) { Modified: php/php-src/trunk/ext/date/lib/interval.c === --- php/php-src/trunk/ext/date/lib/interval.c 2011-12-07 08:37:48 UTC (rev 320562) +++ php/php-src/trunk/ext/date/lib/interval.c 2011-12-07 08:39:43 UTC (rev 320563) @@ -19,6 +19,7 @@ /* $Id$ */ #include timelib.h +#include math.h timelib_rel_time *timelib_diff(timelib_time *one, timelib_time *two) { -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/date/tests/bug48678.phpt branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt branches/PHP_5_4/ext/date/tests/bug48678.phpt trunk/ext/date
pajoye Wed, 07 Dec 2011 09:03:07 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320564 Log: - print_r seems to display 0 or nothing for days, let make that test works in both cases, that's not the purpose of this test to test print_r Changed paths: U php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt U php/php-src/trunk/ext/date/tests/bug48678.phpt Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -6,7 +6,7 @@ print_r($x); $y = unserialize(serialize($x)); print_r($y); ---EXPECT-- +--EXPECTF-- DateInterval Object ( [y] = 3 @@ -16,7 +16,7 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) DateInterval Object ( @@ -27,5 +27,5 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) Modified: php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -1,5 +1,9 @@ --TEST-- date_default_timezone_set() function [1] +--SKIPIF-- +?php +if (substr(PHP_OS, 0, 3) == 'WIN') die('skip diff TZ detection on windows.'); +? --INI-- date.timezone= --FILE-- Modified: php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt === --- php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -6,7 +6,7 @@ print_r($x); $y = unserialize(serialize($x)); print_r($y); ---EXPECT-- +--EXPECTF-- DateInterval Object ( [y] = 3 @@ -16,7 +16,7 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) DateInterval Object ( @@ -27,5 +27,5 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) Modified: php/php-src/trunk/ext/date/tests/bug48678.phpt === --- php/php-src/trunk/ext/date/tests/bug48678.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/trunk/ext/date/tests/bug48678.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -6,7 +6,7 @@ print_r($x); $y = unserialize(serialize($x)); print_r($y); ---EXPECT-- +--EXPECTF-- DateInterval Object ( [y] = 3 @@ -16,7 +16,7 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) DateInterval Object ( @@ -27,5 +27,5 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/trunk/main/ php_ini.c
laruence Wed, 07 Dec 2011 10:28:56 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320566 Log: Merge -r317306 to trunk Changed paths: U php/php-src/trunk/main/php_ini.c Modified: php/php-src/trunk/main/php_ini.c === --- php/php-src/trunk/main/php_ini.c2011-12-07 10:09:33 UTC (rev 320565) +++ php/php-src/trunk/main/php_ini.c2011-12-07 10:28:56 UTC (rev 320566) @@ -421,7 +421,11 @@ env_location = ; } else { size = GetEnvironmentVariableA(PHPRC, phprc_path, size); - env_location = phprc_path; + if (size == 0) { + env_location = ; + } else { + env_location = phprc_path; + } } } } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_ini.c branches/PHP_5_4/tests/basic/bug54514.phpt trunk/mai
laruence Wed, 07 Dec 2011 10:33:13 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320567 Log: Implemented FR #54514 (Get php binary path during script execution). Bug: https://bugs.php.net/54514 (Open) Get php binary path during script execution Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/branches/PHP_5_4/main/php_globals.h U php/php-src/branches/PHP_5_4/main/php_ini.c A php/php-src/branches/PHP_5_4/tests/basic/bug54514.phpt U php/php-src/trunk/main/main.c U php/php-src/trunk/main/php_globals.h U php/php-src/trunk/main/php_ini.c A php/php-src/trunk/tests/basic/bug54514.phpt Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-07 10:28:56 UTC (rev 320566) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-07 10:33:13 UTC (rev 320567) @@ -6,6 +6,8 @@ (php at mickweiss dot com) . Fixed bug #60240 (invalid read/writes when unserializing specially crafted strings). (Mike) + . Implement FR #54514 (Get php binary path during script execution). +(Laruence) - CLI SAPI: . Implement FR #60390 (Missing $_SERVER['SERVER_PORT']). (Pierre) Modified: php/php-src/branches/PHP_5_4/main/main.c === --- php/php-src/branches/PHP_5_4/main/main.c 2011-12-07 10:28:56 UTC (rev 320566) +++ php/php-src/branches/PHP_5_4/main/main.c 2011-12-07 10:33:13 UTC (rev 320567) @@ -255,6 +255,57 @@ } /* }}} */ +/* {{{ php_binary_init + */ +static void php_binary_init(TSRMLS_D) +{ + char *binary_location; +#ifdef PHP_WIN32 + binary_location = (char *)malloc(MAXPATHLEN); + if (GetModuleFileName(0, binary_location, MAXPATHLEN) == 0) { + free(binary_location); + PG(php_binary) = NULL; + } +#else + if (sapi_module.executable_location) { + binary_location = (char *)malloc(MAXPATHLEN); + if (!strchr(sapi_module.executable_location, '/')) { + char *envpath, *path; + int found = 0; + + if ((envpath = getenv(PATH)) != NULL) { +char *search_dir, search_path[MAXPATHLEN]; +char *last = NULL; + +path = estrdup(envpath); +search_dir = php_strtok_r(path, :, last); + +while (search_dir) { + snprintf(search_path, MAXPATHLEN, %s/%s, search_dir, sapi_module.executable_location); + if (VCWD_REALPATH(search_path, binary_location) !VCWD_ACCESS(binary_location, X_OK)) { + found = 1; + break; + } + search_dir = php_strtok_r(NULL, :, last); +} +efree(path); + } + if (!found) { +free(binary_location); +binary_location = NULL; + } + } else if (!VCWD_REALPATH(sapi_module.executable_location, binary_location) || VCWD_ACCESS(binary_location, X_OK)) { + free(binary_location); + binary_location = NULL; + } + } else { + binary_location = NULL; + } +#endif + PG(php_binary) = binary_location; +} +/* }}} */ + /* {{{ PHP_INI_MH */ static PHP_INI_MH(OnUpdateTimeout) @@ -1819,6 +1870,9 @@ if (core_globals-disable_classes) { free(core_globals-disable_classes); } + if (core_globals-php_binary) { + free(core_globals-php_binary); + } php_shutdown_ticks(TSRMLS_C); } @@ -2069,6 +2123,13 @@ REGISTER_MAIN_LONG_CONSTANT(PHP_WINDOWS_NT_WORKSTATION, VER_NT_WORKSTATION, CONST_PERSISTENT | CONST_CS); #endif + php_binary_init(TSRMLS_C); + if (PG(php_binary)) { + REGISTER_MAIN_STRINGL_CONSTANT(PHP_BINARY, PG(php_binary), strlen(PG(php_binary)), CONST_PERSISTENT | CONST_CS); + } else { + REGISTER_MAIN_STRINGL_CONSTANT(PHP_BINARY, , 0, CONST_PERSISTENT | CONST_CS); + } + php_output_register_constants(TSRMLS_C); php_rfc1867_register_constants(TSRMLS_C); Modified: php/php-src/branches/PHP_5_4/main/php_globals.h === --- php/php-src/branches/PHP_5_4/main/php_globals.h 2011-12-07 10:28:56 UTC (rev 320566) +++ php/php-src/branches/PHP_5_4/main/php_globals.h 2011-12-07 10:33:13 UTC (rev 320567) @@ -84,6 +84,7 @@ char *include_path; char *open_basedir; char *extension_dir; + char *php_binary; char *upload_tmp_dir; long upload_max_filesize; Modified: php/php-src/branches/PHP_5_4/main/php_ini.c === --- php/php-src/branches/PHP_5_4/main/php_ini.c 2011-12-07 10:28:56 UTC (rev 320566) +++ php/php-src/branches/PHP_5_4/main/php_ini.c 2011-12-07 10:33:13 UTC (rev 320567) @@ -393,7 +393,6 @@ int search_path_size; char *default_location; char *env_location; - char *binary_location; static const char paths_separator[] = { ZEND_PATHS_SEPARATOR, 0 }; #ifdef PHP_WIN32 char *reg_location; @@ -472,52 +471,12 @@ strlcat(php_ini_search_path, ., search_path_size); } - /* Add binary directory */ -#ifdef PHP_WIN32 - binary_location = (char *) emalloc(MAXPATHLEN); - if
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/ext/date/tests/bug52062.phpt trunk/ext/date/tests/bug52062.phpt
pajoye Wed, 07 Dec 2011 10:38:35 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320568 Log: - tests require 64bit integer Changed paths: U php/php-src/branches/PHP_5_4/ext/date/tests/bug52062.phpt U php/php-src/trunk/ext/date/tests/bug52062.phpt Modified: php/php-src/branches/PHP_5_4/ext/date/tests/bug52062.phpt === --- php/php-src/branches/PHP_5_4/ext/date/tests/bug52062.phpt 2011-12-07 10:33:13 UTC (rev 320567) +++ php/php-src/branches/PHP_5_4/ext/date/tests/bug52062.phpt 2011-12-07 10:38:35 UTC (rev 320568) @@ -1,5 +1,11 @@ --TEST-- Bug #52062: large timestamps with DateTime::getTimestamp and DateTime::setTimestamp +--SKIPIF-- +?php +if (PHP_INT_SIZE == 4) die('skip tests require 64bit integer (php\' int, long in C.'); +? +--INI-- +date.timezone=UTC --FILE-- ?php $d = new DateTime('@1000'); Modified: php/php-src/trunk/ext/date/tests/bug52062.phpt === --- php/php-src/trunk/ext/date/tests/bug52062.phpt 2011-12-07 10:33:13 UTC (rev 320567) +++ php/php-src/trunk/ext/date/tests/bug52062.phpt 2011-12-07 10:38:35 UTC (rev 320568) @@ -1,5 +1,11 @@ --TEST-- Bug #52062: large timestamps with DateTime::getTimestamp and DateTime::setTimestamp +--SKIPIF-- +?php +if (PHP_INT_SIZE == 4) die('skip tests require 64bit integer (php\' int, long in C.'); +? +--INI-- +date.timezone=UTC --FILE-- ?php $d = new DateTime('@1000'); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_ini.c branches/PHP_5_4/tests/basic/bug54514.phpt trunk
this patch is not correct, php crashes on startup when a request is initialized. ==7872==at 0x816204B: php_auto_globals_create_request (php_variables.c:804) ==7872==by 0x818E564: zend_auto_global_init (zend_compile.c:6694) ==7872==by 0x81BB0CE: zend_hash_apply (zend_hash.c:716) ==7872==by 0x818FFEA: zend_activate_auto_globals (zend_compile.c:6704) ==7872==by 0x81629BE: php_hash_environment (php_variables.c:629) ==7872==by 0x8154D1C: php_request_startup (main.c:1567) ==7872==by 0x82507CD: do_cli (php_cli.c:954) ==7872==by 0x8251403: main (php_cli.c:1356) or on windows: php_auto_globals_create_request(const char * name=0x10663298, unsigned int name_len=8, void * * * tsrm_ls=0x026a4f60) Line 804 + 0x16 bytes C zend_auto_global_init(_zend_auto_global * auto_global=0x029a3620, void * * * tsrm_ls=0x026a4f60) Line 6694 + 0x1b bytes C zend_hash_apply(_hashtable * ht=0x029ebd40, int (void *, void * * *)* apply_func=0x1026b880, void * * * tsrm_ls=0x026a4f60) Line 716 + 0x10 bytes C zend_activate_auto_globals(void * * * tsrm_ls=0x026a4f60) Line 6704 + 0x23 bytes C php_hash_environment(void * * * tsrm_ls=0x026a4f60) Line 629 + 0x9 bytes C php_request_startup(void * * * tsrm_ls=0x026a4f60) Line 1567 + 0x9 bytes C do_cli(int argc=6, char * * argv=0x026a4e28, void * * * tsrm_ls=0x026a4f60) Line 954 + 0xc bytes C main(int argc=6, char * * argv=0x026a4e28) Line 1356 + 0x11 bytes C __tmainCRTStartup() Line 586 + 0x19 bytes C mainCRTStartup() Line 403 C On Wed, Dec 7, 2011 at 11:33 AM, Xinchen Hui larue...@php.net wrote: laruence Wed, 07 Dec 2011 10:33:13 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320567 Log: Implemented FR #54514 (Get php binary path during script execution). Bug: https://bugs.php.net/54514 (Open) Get php binary path during script execution Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/branches/PHP_5_4/main/php_globals.h U php/php-src/branches/PHP_5_4/main/php_ini.c A php/php-src/branches/PHP_5_4/tests/basic/bug54514.phpt U php/php-src/trunk/main/main.c U php/php-src/trunk/main/php_globals.h U php/php-src/trunk/main/php_ini.c A php/php-src/trunk/tests/basic/bug54514.phpt -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_ini.c branches/PHP_5_4/tests/basic/bug54514.phpt trunk
seems to be due to partially generated global table, clean build and I cannot reproduce the crash anymore. Sorry for the noise :) On Wed, Dec 7, 2011 at 12:20 PM, Pierre Joye pierre@gmail.com wrote: this patch is not correct, php crashes on startup when a request is initialized. -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/curl/tests/bug27023.phpt branches/PHP_5_3/ext/curl/tests/responder/get.php branches/PHP_5_4/ext/curl/tests/bug27023.phpt branches/PHP_5_4/ext/curl/tes
pierrick Wed, 07 Dec 2011 16:32:50 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320584 Log: Add new test for CURLOPT_POSTFIELDS Changed paths: A php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt U php/php-src/branches/PHP_5_3/ext/curl/tests/responder/get.php A php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt U php/php-src/branches/PHP_5_4/ext/curl/tests/responder/get.php A php/php-src/trunk/ext/curl/tests/bug27023.phpt U php/php-src/trunk/ext/curl/tests/responder/get.php Added: php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt === --- php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt (rev 0) +++ php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt 2011-12-07 16:32:50 UTC (rev 320584) @@ -0,0 +1,48 @@ +--TEST-- +Bug #27023 (CURLOPT_POSTFIELDS does not parse content types for files) +--SKIPIF-- +?php +if (!extension_loaded(curl)) { + exit(skip curl extension not loaded); +} +if (false === getenv('PHP_CURL_HTTP_REMOTE_SERVER')) { + exit(skip PHP_CURL_HTTP_REMOTE_SERVER env variable is not defined); +} +? +--FILE-- +?php + +$host = getenv('PHP_CURL_HTTP_REMOTE_SERVER'); +$ch = curl_init(); +curl_setopt($ch, CURLOPT_URL, {$host}/get.php?test=file); +curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;filename=foo.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + + +curl_close($ch); +? +--EXPECTF-- +string(%d) curl_testdata1.txt|application/octet-stream +string(%d) curl_testdata1.txt|text/plain +string(%d) foo.txt|application/octet-stream +string(%d) foo.txt|text/plain +string(%d) foo.txt|text/plain Modified: php/php-src/branches/PHP_5_3/ext/curl/tests/responder/get.php === --- php/php-src/branches/PHP_5_3/ext/curl/tests/responder/get.php 2011-12-07 16:27:28 UTC (rev 320583) +++ php/php-src/branches/PHP_5_3/ext/curl/tests/responder/get.php 2011-12-07 16:32:50 UTC (rev 320584) @@ -25,6 +25,11 @@ case 'contenttype': header('Content-Type: text/plain;charset=utf-8'); break; +case 'file': + if (isset($_FILES['file'])) { + echo $_FILES['file']['name'] . '|' . $_FILES['file']['type']; + } + break; default: echo Hello World!\n; echo Hello World!; Added: php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt === --- php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt 2011-12-07 16:32:50 UTC (rev 320584) @@ -0,0 +1,48 @@ +--TEST-- +Bug #27023 (CURLOPT_POSTFIELDS does not parse content types for files) +--SKIPIF-- +?php +if (!extension_loaded(curl)) { + exit(skip curl extension not loaded); +} +if (false === getenv('PHP_CURL_HTTP_REMOTE_SERVER')) { + exit(skip PHP_CURL_HTTP_REMOTE_SERVER env variable is not defined); +} +? +--FILE-- +?php + +$host = getenv('PHP_CURL_HTTP_REMOTE_SERVER'); +$ch = curl_init(); +curl_setopt($ch, CURLOPT_URL, {$host}/get.php?test=file); +curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;filename=foo.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + + +curl_close($ch); +? +--EXPECTF-- +string(%d) curl_testdata1.txt|application/octet-stream +string(%d)
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/curl/tests/bug27023.phpt branches/PHP_5_4/ext/curl/tests/bug27023.phpt trunk/ext/curl/tests/bug27023.phpt
pierrick Wed, 07 Dec 2011 16:46:48 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320585 Log: Fix test Changed paths: U php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt U php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt U php/php-src/trunk/ext/curl/tests/bug27023.phpt Modified: php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt === --- php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt 2011-12-07 16:32:50 UTC (rev 320584) +++ php/php-src/branches/PHP_5_3/ext/curl/tests/bug27023.phpt 2011-12-07 16:46:48 UTC (rev 320585) @@ -33,7 +33,7 @@ curl_setopt($ch, CURLOPT_POSTFIELDS, $params); var_dump(curl_exec($ch)); -$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;filename=foo.txt;type=text/plain'); curl_setopt($ch, CURLOPT_POSTFIELDS, $params); var_dump(curl_exec($ch)); Modified: php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt === --- php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt 2011-12-07 16:32:50 UTC (rev 320584) +++ php/php-src/branches/PHP_5_4/ext/curl/tests/bug27023.phpt 2011-12-07 16:46:48 UTC (rev 320585) @@ -33,7 +33,7 @@ curl_setopt($ch, CURLOPT_POSTFIELDS, $params); var_dump(curl_exec($ch)); -$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;filename=foo.txt;type=text/plain'); curl_setopt($ch, CURLOPT_POSTFIELDS, $params); var_dump(curl_exec($ch)); Modified: php/php-src/trunk/ext/curl/tests/bug27023.phpt === --- php/php-src/trunk/ext/curl/tests/bug27023.phpt 2011-12-07 16:32:50 UTC (rev 320584) +++ php/php-src/trunk/ext/curl/tests/bug27023.phpt 2011-12-07 16:46:48 UTC (rev 320585) @@ -33,7 +33,7 @@ curl_setopt($ch, CURLOPT_POSTFIELDS, $params); var_dump(curl_exec($ch)); -$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;type=text/plain;filename=foo.txt'); +$params = array('file' = '@' . __DIR__ . '/curl_testdata1.txt;filename=foo.txt;type=text/plain'); curl_setopt($ch, CURLOPT_POSTFIELDS, $params); var_dump(curl_exec($ch)); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/date/tests/bug48678.phpt branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt branches/PHP_5_4/ext/date/tests/bug48678.phpt trunk/ext/
On Wed, 7 Dec 2011, Pierre Joye wrote: pajoye Wed, 07 Dec 2011 09:03:07 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320564 Log: - print_r seems to display 0 or nothing for days, let make that test works in both cases, that's not the purpose of this test to test print_r This is actually a bug that I haven't fixed yet. 0 is int 0, and nothing is false. It should return false, but right now it doesn't. Could you revert this changes, as there is a real bug in the code (and I'd rather fix the bug, then hide it with a passing test :)). Changed paths: U php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt U php/php-src/trunk/ext/date/tests/bug48678.phpt Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -6,7 +6,7 @@ print_r($x); $y = unserialize(serialize($x)); print_r($y); ---EXPECT-- +--EXPECTF-- DateInterval Object ( [y] = 3 @@ -16,7 +16,7 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) DateInterval Object ( @@ -27,5 +27,5 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) Modified: php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/branches/PHP_5_3/ext/date/tests/date_default_timezone_set-1.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -1,5 +1,9 @@ --TEST-- date_default_timezone_set() function [1] +--SKIPIF-- +?php +if (substr(PHP_OS, 0, 3) == 'WIN') die('skip diff TZ detection on windows.'); +? --INI-- date.timezone= --FILE-- Modified: php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt === --- php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt 2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt 2011-12-07 09:03:07 UTC (rev 320564) @@ -6,7 +6,7 @@ print_r($x); $y = unserialize(serialize($x)); print_r($y); ---EXPECT-- +--EXPECTF-- DateInterval Object ( [y] = 3 @@ -16,7 +16,7 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) DateInterval Object ( @@ -27,5 +27,5 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) Modified: php/php-src/trunk/ext/date/tests/bug48678.phpt === --- php/php-src/trunk/ext/date/tests/bug48678.phpt2011-12-07 08:39:43 UTC (rev 320563) +++ php/php-src/trunk/ext/date/tests/bug48678.phpt2011-12-07 09:03:07 UTC (rev 320564) @@ -6,7 +6,7 @@ print_r($x); $y = unserialize(serialize($x)); print_r($y); ---EXPECT-- +--EXPECTF-- DateInterval Object ( [y] = 3 @@ -16,7 +16,7 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) DateInterval Object ( @@ -27,5 +27,5 @@ [i] = 30 [s] = 5 [invert] = 0 -[days] = +[days] =%s ) -- http://derickrethans.nl | http://xdebug.org Like Xdebug? Consider a donation: http://xdebug.org/donate.php twitter: @derickr and @xdebug -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/date/tests/bug28088.phpt branches/PHP_5_3/ext/date/tests/bug33415-2.phpt branches/PHP_5_3/ext/date/tests/bug51223.phpt branches/PHP_5_3/ext/date/tests
derick Wed, 07 Dec 2011 19:24:58 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320604 Log: Sorting out the tests *once* more. Please keep them consistent and only change them if you are 110% certain what you're doing. Otherwise - please ask. Changed paths: U php/php-src/branches/PHP_5_3/ext/date/tests/bug28088.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug33415-2.phpt D php/php-src/branches/PHP_5_3/ext/date/tests/bug51223.phpt A php/php-src/branches/PHP_5_3/ext/date/tests/bug52062-64bit.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug52062.phpt A + php/php-src/branches/PHP_5_3/ext/date/tests/bug52113.phpt (from php/php-src/branches/PHP_5_3/ext/date/tests/bug51223.phpt:r320599) U php/php-src/branches/PHP_5_3/ext/date/tests/bug53502.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/gmstrftime_variation22.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/strftime_variation22.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/DateInterval_format.phpt A php/php-src/branches/PHP_5_4/ext/date/tests/DateInterval_format_a.phpt A php/php-src/branches/PHP_5_4/ext/date/tests/bug52062-64bit.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug52062.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug53502.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/date_default_timezone_set-1.phpt U php/php-src/trunk/ext/date/tests/DateInterval_format.phpt A php/php-src/trunk/ext/date/tests/DateInterval_format_a.phpt A php/php-src/trunk/ext/date/tests/bug52062-64bit.phpt U php/php-src/trunk/ext/date/tests/bug52062.phpt U php/php-src/trunk/ext/date/tests/bug53502.phpt Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug28088.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug28088.phpt 2011-12-07 19:22:44 UTC (rev 320603) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug28088.phpt 2011-12-07 19:24:58 UTC (rev 320604) @@ -1,9 +1,9 @@ --TEST-- Bug #28088 (strtotime() cannot convert 00 hours) +--INI-- +date.timezone=UTC --FILE-- ?php -putenv(TZ=GMT); - echo The following line rightly shows the correct date time:\n; echo gmdate(m/d/y Hi, strtotime(04/04/04 2345)), \n; Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug33415-2.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug33415-2.phpt 2011-12-07 19:22:44 UTC (rev 320603) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug33415-2.phpt 2011-12-07 19:24:58 UTC (rev 320604) @@ -2,14 +2,10 @@ Bug #33415 [2] (Possibly invalid non-one-hour DST or timezone shifts) --FILE-- ?php +date_default_timezone_set('Africa/Bujumbura'); print TZ=Africa/Bujumbura - *Note*: Unexpected, as does not appear to have a DST or timezone transition.\n; -if (defined('PHP_WINDOWS_VERSION_MAJOR')) { - date_default_timezone_set('Africa/Bujumbura'); -} else { - putenv(TZ=Africa/Bujumbura); -} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print tStamp=. date(l Y-m-d H:i:s T I, $tStamp). \n; $strtotime_tstamp = strtotime(next Wednesday, $tStamp); @@ -17,11 +13,7 @@ print wanted=Wednesday00:00:00\n\n; print TZ=Asia/Thimbu - Is it OK for this to be 0:30 AM? yes\n; -if (defined('PHP_WINDOWS_VERSION_MAJOR')) { - date_default_timezone_set('Asia/Thimbu'); -} else { - putenv(TZ=Asia/Thimbu); -} +date_default_timezone_set('Asia/Thimbu'); $tStamp = mktime (17, 17, 17, 1, 6476, 1970); print tStamp=. date(l Y-m-d H:i:s T I, $tStamp). \n; $strtotime_tstamp = strtotime(next Thursday, $tStamp); @@ -30,11 +22,7 @@ print TZ=Indian/Cocos - Is it OK for this to be 6:30 AM? Note: does not appear to have a DST or timezone transition.\n; -if (defined('PHP_WINDOWS_VERSION_MAJOR')) { - date_default_timezone_set('Indian/Cocos'); -} else { - putenv(TZ=Indian/Cocos); -} +date_default_timezone_set('Indian/Cocos'); $tStamp = mktime (17, 17, 17, 1, 1, 1970); print tStamp=. date(l Y-m-d H:i:s T I, $tStamp). \n; $strtotime_tstamp = strtotime(next Thursday, $tStamp); @@ -43,11 +31,7 @@ print TZ=Africa/Lubumbashi - Is it OK for this to be 2 AM? Note: does not appear to have a DST or timezone transition.\n; -if (defined('PHP_WINDOWS_VERSION_MAJOR')) { - date_default_timezone_set('Africa/Lubumbashi'); -} else { - putenv(TZ=Africa/Lubumbashi); -} +date_default_timezone_set('Africa/Lubumbashi'); $tStamp = mktime (17, 17, 17, 1, 1, 1970); print tStamp=. date(l Y-m-d H:i:s T I, $tStamp). \n; $strtotime_tstamp = strtotime(next Saturday, $tStamp); @@ -55,11 +39,7 @@ print wanted=Saturday00:00:00\n\n; print TZ=Asia/Kashgar - Is it OK for this to be 3 AM? yes\n; -if (defined('PHP_WINDOWS_VERSION_MAJOR')) { - date_default_timezone_set('Asia/Kashgar'); -} else { - putenv(TZ=Asia/Kashgar); -} +date_default_timezone_set('Asia/Kashgar'); $tStamp =
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_3/ext/date/tests/bug48476.phpt branches/PHP_5_3/ext/date/tests/bug48678.phpt branches/PHP_5_3/ext/date/tests/bug50392.phpt branches/PHP_5_3/ext/date/tests/b
derick Wed, 07 Dec 2011 19:42:44 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320605 Log: Test cosmetics. Changed paths: U php/php-src/branches/PHP_5_3/ext/date/tests/bug48476.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug50392.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug51096.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug52062-64bit.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug52062.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug52113.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug53437.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug53502.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug54597.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug54851.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug55253.phpt U php/php-src/branches/PHP_5_3/ext/date/tests/bug60236.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug48476.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug48678.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug50392.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug51096.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug52062-64bit.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug52062.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug52113.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug53437.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug53502.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug54597.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug54851.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug55253.phpt U php/php-src/branches/PHP_5_4/ext/date/tests/bug60236.phpt U php/php-src/trunk/ext/date/tests/bug48476.phpt U php/php-src/trunk/ext/date/tests/bug48678.phpt U php/php-src/trunk/ext/date/tests/bug50392.phpt U php/php-src/trunk/ext/date/tests/bug51096.phpt U php/php-src/trunk/ext/date/tests/bug52062-64bit.phpt U php/php-src/trunk/ext/date/tests/bug52062.phpt U php/php-src/trunk/ext/date/tests/bug52113.phpt U php/php-src/trunk/ext/date/tests/bug53437.phpt U php/php-src/trunk/ext/date/tests/bug53502.phpt U php/php-src/trunk/ext/date/tests/bug54597.phpt U php/php-src/trunk/ext/date/tests/bug54851.phpt U php/php-src/trunk/ext/date/tests/bug55253.phpt U php/php-src/trunk/ext/date/tests/bug60236.phpt Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug48476.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug48476.phpt 2011-12-07 19:24:58 UTC (rev 320604) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug48476.phpt 2011-12-07 19:42:44 UTC (rev 320605) @@ -1,5 +1,5 @@ --TEST-- -Bug#48476 (cloning extended DateTime class without calling parent::__constr crashed PHP) +Bug #48476 (cloning extended DateTime class without calling parent::__constr crashed PHP) --FILE-- ?php class MyDateTime extends DateTime { Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt 2011-12-07 19:24:58 UTC (rev 320604) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug48678.phpt 2011-12-07 19:42:44 UTC (rev 320605) @@ -1,5 +1,5 @@ --TEST-- -Bug #48678: DateInterval segfaults when unserialising +Bug #48678 (DateInterval segfaults when unserialising) --FILE-- ?php $x = new DateInterval(P3Y6M4DT12H30M5S); Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug50392.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug50392.phpt 2011-12-07 19:24:58 UTC (rev 320604) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug50392.phpt 2011-12-07 19:42:44 UTC (rev 320605) @@ -1,5 +1,5 @@ --TEST-- -Bug #50392 date_create_from_format enforces 6 digits for 'u' format character +Bug #50392 (date_create_from_format enforces 6 digits for 'u' format character) --FILE-- ?php date_default_timezone_set('Europe/Bratislava'); Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug51096.phpt === --- php/php-src/branches/PHP_5_3/ext/date/tests/bug51096.phpt 2011-12-07 19:24:58 UTC (rev 320604) +++ php/php-src/branches/PHP_5_3/ext/date/tests/bug51096.phpt 2011-12-07 19:42:44 UTC (rev 320605) @@ -1,5 +1,5 @@ --TEST-- -Bug #51096: Test for first day vs first day of. +Bug #51096 (Test for first day vs first day of) --FILE-- ?php $tests = array( Modified: php/php-src/branches/PHP_5_3/ext/date/tests/bug52062-64bit.phpt === ---
[PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/openssl/openssl.c trunk/ext/openssl/openssl.c
scottmac Wed, 07 Dec 2011 20:50:33 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320612 Log: Make sure that we set the strong crypto result to false as well as returning false. Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/openssl/openssl.c U php/php-src/trunk/ext/openssl/openssl.c Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-07 20:36:39 UTC (rev 320611) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-07 20:50:33 UTC (rev 320612) @@ -18,6 +18,10 @@ - Intl: . Added support for UTS #46. (Gustavo) + +- OpenSSL: + . On error in openssl_random_pseudo_bytes() make sure we set strong result +to false. (Scott) - Reflection: . Fixed bug #60367 (Reflection and Late Static Binding). (Laruence) Modified: php/php-src/branches/PHP_5_4/ext/openssl/openssl.c === --- php/php-src/branches/PHP_5_4/ext/openssl/openssl.c 2011-12-07 20:36:39 UTC (rev 320611) +++ php/php-src/branches/PHP_5_4/ext/openssl/openssl.c 2011-12-07 20:50:33 UTC (rev 320612) @@ -4941,13 +4941,19 @@ #ifdef PHP_WIN32 strong_result = 1; /* random/urandom equivalent on Windows */ - if (php_win32_get_random_bytes(buffer, (size_t) buffer_length) == FAILURE){ + if (php_win32_get_random_bytes(buffer, (size_t) buffer_length) == FAILURE) { efree(buffer); + if (zstrong_result_returned) { + ZVAL_BOOL(zstrong_result_returned, 0); + } RETURN_FALSE; } #else if ((strong_result = RAND_pseudo_bytes(buffer, buffer_length)) 0) { efree(buffer); + if (zstrong_result_returned) { + ZVAL_BOOL(zstrong_result_returned, 0); + } RETURN_FALSE; } #endif Modified: php/php-src/trunk/ext/openssl/openssl.c === --- php/php-src/trunk/ext/openssl/openssl.c 2011-12-07 20:36:39 UTC (rev 320611) +++ php/php-src/trunk/ext/openssl/openssl.c 2011-12-07 20:50:33 UTC (rev 320612) @@ -4939,11 +4939,17 @@ /* random/urandom equivalent on Windows */ if (php_win32_get_random_bytes(buffer, (size_t) buffer_length) == FAILURE){ efree(buffer); + if (zstrong_result_returned) { + ZVAL_BOOL(zstrong_result_returned, 0); + } RETURN_FALSE; } #else if ((strong_result = RAND_pseudo_bytes(buffer, buffer_length)) 0) { efree(buffer); + if (zstrong_result_returned) { + ZVAL_BOOL(zstrong_result_returned, 0); + } RETURN_FALSE; } #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
stas Thu, 08 Dec 2011 07:15:44 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320631 Log: 5.4.0rc3 Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/configure.in U php/php-src/branches/PHP_5_4/main/php_version.h Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-08 06:57:34 UTC (rev 320630) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-08 07:15:44 UTC (rev 320631) @@ -1,6 +1,6 @@ PHPNEWS ||| -?? ??? 2011, PHP 5.4.0 RC3 +08 Dec 2011, PHP 5.4.0 RC3 - Core: . Fixed bug #60350 (No string escape code for ESC (ascii 27), normally \e). (php at mickweiss dot com) Modified: php/php-src/branches/PHP_5_4/configure.in === --- php/php-src/branches/PHP_5_4/configure.in 2011-12-08 06:57:34 UTC (rev 320630) +++ php/php-src/branches/PHP_5_4/configure.in 2011-12-08 07:15:44 UTC (rev 320631) @@ -120,7 +120,7 @@ PHP_MAJOR_VERSION=5 PHP_MINOR_VERSION=4 PHP_RELEASE_VERSION=0 -PHP_EXTRA_VERSION=RC3-dev +PHP_EXTRA_VERSION=RC3 PHP_VERSION=$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 1 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION` Modified: php/php-src/branches/PHP_5_4/main/php_version.h === --- php/php-src/branches/PHP_5_4/main/php_version.h 2011-12-08 06:57:34 UTC (rev 320630) +++ php/php-src/branches/PHP_5_4/main/php_version.h 2011-12-08 07:15:44 UTC (rev 320631) @@ -3,6 +3,6 @@ #define PHP_MAJOR_VERSION 5 #define PHP_MINOR_VERSION 4 #define PHP_RELEASE_VERSION 0 -#define PHP_EXTRA_VERSION RC3-dev -#define PHP_VERSION 5.4.0RC3-dev +#define PHP_EXTRA_VERSION RC3 +#define PHP_VERSION 5.4.0RC3 #define PHP_VERSION_ID 50400 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
stas Thu, 08 Dec 2011 07:17:27 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320632 Log: back to dev Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/configure.in U php/php-src/branches/PHP_5_4/main/php_version.h Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-08 07:15:44 UTC (rev 320631) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-08 07:17:27 UTC (rev 320632) @@ -1,5 +1,7 @@ PHPNEWS ||| +?? Dec 2011, PHP 5.4.0 RC4 + 08 Dec 2011, PHP 5.4.0 RC3 - Core: . Fixed bug #60350 (No string escape code for ESC (ascii 27), normally \e). Modified: php/php-src/branches/PHP_5_4/configure.in === --- php/php-src/branches/PHP_5_4/configure.in 2011-12-08 07:15:44 UTC (rev 320631) +++ php/php-src/branches/PHP_5_4/configure.in 2011-12-08 07:17:27 UTC (rev 320632) @@ -120,7 +120,7 @@ PHP_MAJOR_VERSION=5 PHP_MINOR_VERSION=4 PHP_RELEASE_VERSION=0 -PHP_EXTRA_VERSION=RC3 +PHP_EXTRA_VERSION=RC4-dev PHP_VERSION=$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 1 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION` Modified: php/php-src/branches/PHP_5_4/main/php_version.h === --- php/php-src/branches/PHP_5_4/main/php_version.h 2011-12-08 07:15:44 UTC (rev 320631) +++ php/php-src/branches/PHP_5_4/main/php_version.h 2011-12-08 07:17:27 UTC (rev 320632) @@ -3,6 +3,6 @@ #define PHP_MAJOR_VERSION 5 #define PHP_MINOR_VERSION 4 #define PHP_RELEASE_VERSION 0 -#define PHP_EXTRA_VERSION RC3 -#define PHP_VERSION 5.4.0RC3 +#define PHP_EXTRA_VERSION RC4-dev +#define PHP_VERSION 5.4.0RC4-dev #define PHP_VERSION_ID 50400 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] svn: /php/php-src/tags/
stas Thu, 08 Dec 2011 07:20:38 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320633 Log: 5.4.0rc3 Changed paths: A + php/php-src/tags/php_5_4_0RC3/ (from php/php-src/branches/PHP_5_4/:r320631) Property changes on: php/php-src/tags/php_5_4_0RC3 ___ Added: svn:ignore + Makefile.objects Makefile.fragments Makefile acconfig.h aclocal.m4 autom4te.cache bsd_converted buildmk.stamp buildconf.stamp config.h.in config.cache config.log config.status config_vars.mk configuration-parser.c configuration-parser.h configuration-parser.output configuration-scanner.c configure configure.bat conftest conftest.c generated_lists meta_cc meta_ccld mkinstalldirs missing install-sh internal_functions.c libtool shlibtool php php5.spec stamp-h test.php3 *.lo *.la libs modules php-*.tar.gz want_dependencies deps config.nice php_version.h *.plg *.opt *.ncb Release Release_inline Debug Release_TS Release_TSDbg Release_TS_inline Debug_TS results.txt libs _libs include autom4te.cache FBCIndex FBCLockFolder debug.log confdefs.h configure.js config.nice.bat configure.bat ZendEngine1 php_test_results_*.txt *.gcda *.gcno lcov_data lcov_html php_lcov.info tmp-php.ini diff x64 Added: svn:mergeinfo + /php/php-src/trunk:284726 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php