Compare commits

...
943 Commits
Author SHA1 Message Date
Johannes Schlüter 7d14f70776 PHP 5.3.4 2010-12-08 21:41:22 +00:00
Johannes Schlüter 3d76289c59 PHP 5.3.4 2010-12-08 21:38:51 +00:00
Eyal Teutsch eabb9be2ac curl_setopt() arg: using DIRECTORY_SEPARATOR rather then "/" to make windows tests pass too 2010-12-08 14:16:17 +00:00
Pierre Joye f9207e3187 - new warning in imagepstext 2010-12-08 09:38:47 +00:00
Pierre Joye a0eb5848b5 - Fix #53492, fix crash if aa steps are invalid 2010-12-08 08:45:56 +00:00
Pierre Joye cba0322c81 - not anymore in core or builtin 2010-12-07 23:53:51 +00:00
Andrey Hristov fc6e70d8e4 switch this off for the release 2010-12-07 11:13:55 +00:00
Pierre Joye 1504071cb1 - add CVE 2010-12-07 01:22:23 +00:00
Andrey Hristov 5efdfee8c6 Skip additional result sets sent by MySQL 5.5 servers
which break the Protocol API 
(see http://bugs.mysql.com/bug.php?id=58700)
2010-12-06 13:59:14 +00:00
Andrey Hristov 03fd10c479 don't crash if the API is used incorrectly 2010-12-06 13:50:51 +00:00
Felipe Pena 75eeee8f24 - Fixed test (Eyal Teutsch) 2010-12-04 15:57:08 +00:00
Felipe Pena 0aa36e2d97 - Fixed test 2010-12-04 15:48:45 +00:00
Felipe Pena 0f53b4e515 - Fixed tests 2010-12-04 12:28:23 +00:00
Felipe Pena 76ba9b44b4 - Fixed test 2010-12-03 23:25:27 +00:00
Felipe Pena 3dc4f14c6b - Fixed test 2010-12-03 22:58:21 +00:00
Felipe Pena 3e0b63312e - Order 2010-12-03 21:09:47 +00:00
Felipe Pena 689d1d9e4b - Fixed bug #53463 (sqlite3 columnName() segfaults on bad column_number) 2010-12-03 21:05:44 +00:00
Jani Taskinen 686c7fec26 - CS + reorder to match trunk better, removed trailing dots from error messages 2010-12-03 16:04:24 +00:00
Jani Taskinen 85ef85a0b4 - Fix test 2010-12-03 16:02:47 +00:00
Jani Taskinen f561727ee0 - Add test for the ob_start($foo); leak/crash bug 2010-12-03 15:30:21 +00:00
Jani Taskinen c8e40e49d7 - Fix leaks and crash bug when passing the callback as variable 2010-12-03 13:20:13 +00:00
Pierre Joye 63d87a0adb - Fix #29085, bad default include_path on Windows 2010-12-02 23:23:14 +00:00
Felipe Pena 06c183b761 - Cosmetics 2010-12-02 23:01:04 +00:00
Pierre Joye aef55bc5f3 - some missing entries 2010-12-02 22:56:57 +00:00
Andrey Hristov 9f045cd40e fix test after newly introduced constant 2010-12-02 19:11:41 +00:00
Johannes Schlüter 094bcdff8b - Back to -dev 2010-12-02 14:34:32 +00:00
Andrey Hristov 334e62a77d and export the new constant 2010-12-02 14:21:23 +00:00
Andrey Hristov 3da811a124 new server constant as of 5.5 2010-12-02 13:59:56 +00:00
Johannes Schlüter f915973c1e - PHP 5.3.4RC2 2010-12-02 13:59:38 +00:00
Pierre Joye cd62a70863 - not TS and useless on server, also not required anymore with the supported windows versions 2010-12-02 11:37:43 +00:00
Adam Harvey 92fa280b96 Minimal fix for bug #53440 (INSTALL file refers to php.ini-dist, should refer
to php.ini-production). There are a lot more issues with the INSTALL file,
though, which I'll file another bug for.
2010-12-02 03:26:37 +00:00
Christopher Jones 24c87d760d Remove OCI8 devel status in preparation for PHP 5.3.4 release 2010-12-01 23:30:28 +00:00
Christopher Jones 2024790fd2 Add Berkeley DB 5.1 support to the DBA extension 2010-12-01 19:20:16 +00:00
Ilia Alshanetsky d506ce8d94 Fixed bug #51250 (iconv_mime_decode() does not ignore malformed Q-encoded words) 2010-12-01 14:03:36 +00:00
Andrey Hristov 4adcc3c7bc add a comment 2010-12-01 10:16:51 +00:00
Jérôme Loyet 4c76006fe3 - Fixed bug #53412 (segfault when using -y) 2010-11-30 19:37:10 +00:00
Ilia Alshanetsky 964eff5276 Missing bits from last commit 2010-11-30 16:11:27 +00:00
Ilia Alshanetsky 085e8b781c Fixed bug #52202 (CURLOPT_PRIVATE gets corrupted). 2010-11-30 13:40:02 +00:00
Pierre Joye 761c62267f Fixed crash in zip extract method (possible CWE-170) 2010-11-30 11:04:06 +00:00
Ilia Alshanetsky f719d3707d Fixed bug #52656 (DOMCdataSection does not work with splitText). 2010-11-29 14:48:53 +00:00
Ilia Alshanetsky dd92188d76 Fixed bug #52828 (curl_setopt does not accept persistent streams). 2010-11-29 14:40:59 +00:00
Adam Harvey 7111501381 Update INI files per doc bug #53420 (mail.log is poorly documented). 2010-11-29 03:44:56 +00:00
Derick Rethans e16265aa0e - Reorganize slightly as there was already a date and an intl extension
header/section.
2010-11-28 16:33:07 +00:00
Derick Rethans 688b347d84 - Fixed two more test cases. 2010-11-28 16:27:49 +00:00
Derick Rethans 8cf9513bb9 - Fixed a few test cases. 2010-11-28 13:41:06 +00:00
Ilia Alshanetsky 3239a25e53 Missing bit from previous commit 2010-11-26 21:00:03 +00:00
Ilia Alshanetsky f28cff1925 Fixed bug #52327 (base64_decode() improper handling of leading padding in strict mode) 2010-11-26 20:59:13 +00:00
Pierre Joye c70397b3a9 - Fixed #53409, sleep() return NULL on Windows 2010-11-26 18:25:13 +00:00
Jérôme Loyet f13f4bc872 - Fixed bug #52501 (libevent made FPM crashed when forking -- libevent has been removed) 2010-11-26 13:46:15 +00:00
Johannes Schlüter 222e0bc0f6 - Remove outdated, unmaintained, misleading ChangeLog files 2010-11-26 13:21:25 +00:00
Ilia Alshanetsky 523da85c11 Fixed bug #53304 (quot_print_decode does not handle lower-case hex digits) 2010-11-25 21:38:06 +00:00
Gustavo André dos Santos Lopes 05abc63d14 - Fixed bug #53403 (use of unitialized values). Fixes the fix for bug #46587.
- Added test for bug #46587.
2010-11-25 16:44:20 +00:00
Felipe Pena dbeef88661 - Ordering 2010-11-25 00:05:03 +00:00
Pierre Joye 2ba369cdfa - fixed #53352 2010-11-23 22:14:54 +00:00
Felipe Pena a9a2eb4a14 - Fixed compile warnings 2010-11-23 21:49:18 +00:00
Felipe Pena ac15afe9c1 - Fixed test 2010-11-23 21:45:22 +00:00
Ilia Alshanetsky 4f3ab10786 Fixed bug #46587 (mt_rand() does not check that max is greater than min). 2010-11-23 13:09:15 +00:00
Christopher Jones 8ed386997f Explicitly name the added constant 2010-11-22 22:18:30 +00:00
Ilia Alshanetsky a40667d756 Fixed bug #51003 (unaligned memory access in ext/hash/hash_tiger.c). 2010-11-22 13:12:28 +00:00
Ilia Alshanetsky 534395e4ae Fixed bug #51003 (unaligned memory access in ext/hash/hash_tiger.c) 2010-11-22 13:10:13 +00:00
Gustavo André dos Santos Lopes 2a545be57f - Fix tests for \0 patch in PHP 5.3.
- Fix constants_error_004.phpt (closes bug #51901)
2010-11-22 05:10:14 +00:00
Felipe Pena 167e51f36c - Fixed ZTS build 2010-11-21 17:41:33 +00:00
Felipe Pena abb7038cbf - New NEWS structure (to be improved) 2010-11-21 14:07:22 +00:00
Johannes Schlüter ac4f3422bc - Improve test 2010-11-21 12:28:10 +00:00
Johannes Schlüter 9ea04e1e46 - Fix #52854 (ReflectionClass::newInstanceArgs does not work for classes without constructors 2010-11-21 12:24:09 +00:00
Felipe Pena 1ac484d1a1 - Fixed bug #53366 (Reflection doesnt get dynamic property value from getProperty()) 2010-11-20 22:53:55 +00:00
Kalle Sommer Nielsen 78f10489ca Added second fix from #50987 that wasn't apart of Ilia's commit 2010-11-20 20:59:28 +00:00
Ilia Alshanetsky 5f1b91a6bf Fixed bug #50987 (unaligned memory access in phar.c) 2010-11-20 19:27:31 +00:00
Stanislav Malyshev 4415b3af51 Add support for DateTime in datefmt_format 2010-11-20 02:09:04 +00:00
Christopher Jones c8462df127 Remove unreverted duplicate fix for nulls 2010-11-20 01:29:03 +00:00
Stanislav Malyshev f061627899 report intl fix 2010-11-19 23:27:52 +00:00
Stanislav Malyshev e6c213b8ea Fix invalid args bugs by Maksymilian Arciemowicz 2010-11-19 23:22:55 +00:00
Felipe Pena 93a4e0d1fa - Fixed extract() to do not overwrite $GLOBALS and $this when using EXTR_OVERWRITE.
patch by: jorto at redhat dot com
2010-11-19 22:06:44 +00:00
Felipe Pena f16059d697 - Fixed bug #53362 (Segmentation fault when extending SplFixedArray) 2010-11-19 20:07:32 +00:00
Martin Jansen 61d97af18b Fixed two typos in NEWS. 2010-11-19 18:38:23 +00:00
Ilia Alshanetsky a8b4724747 Fixed bug #47168 (printf of floating point variable prints maximum of 40 decimal places). 2010-11-19 16:36:10 +00:00
Jani Taskinen caf792940f - Merged check from trunk to prevent building multiple SAPIs (bug #52419) 2010-11-19 08:26:47 +00:00
Christopher Jones 64f21f63ad Update fix proviso now the mentioned Oracle bugfix is available in an Oracle patchset 2010-11-19 00:14:58 +00:00
Gustavo André dos Santos Lopes cdab5577c0 - Fixed borked test bug52820.phpt.
- Synced htmlentities17.phpt with trunk; there's no ≀ entity
  in HTML 4.01.
2010-11-18 21:44:42 +00:00
Johannes Schlüter 63f65b6e8f Back to -dev 2010-11-18 19:03:59 +00:00
Johannes Schlüter 7a8d9ad16a - 5.3.4RC1 2010-11-18 17:57:54 +00:00
Pierre Joye f5570be3a9 - path with null entries 2010-11-18 17:09:27 +00:00
Pierre Joye ff26185322 - revert part of the null fix, was already applied by Chris 2010-11-18 16:16:26 +00:00
Pierre Joye ce96fd6b07 - fix #39863, do not accept paths with NULL in them. See http://news.php.net/php.internals/50191, trunk will have the patch later (adding a macro and/or changing (some) APIs. Patch by Rasmus 2010-11-18 15:22:22 +00:00
Gustavo André dos Santos Lopes 75631ab8ac - Implemented alternative strategy for change in rev #304985 so as to
not to break binary compatibility in the 5.3 branch.
2010-11-18 12:10:17 +00:00
Felipe Pena 60ad3e54af - Fix build 2010-11-18 11:33:42 +00:00
Derick Rethans 95a88f04a9 - Fixed the call as well. 2010-11-18 11:28:07 +00:00
Derick Rethans a2434bb66c - Revert the ABI changing commit. 2010-11-18 11:24:59 +00:00
Gustavo André dos Santos Lopes 267634b766 - Fixed NULL dereference in lex_scan on zend multibyte builds where the script
had a flex incompatible encoding and there was no converter.
#see rev #305464 and rev #305466.
2010-11-18 04:14:49 +00:00
Gustavo André dos Santos Lopes a31f379367 - Reversed implementation of FR #44164, pending further consideration.
See rev #304903.
2010-11-18 04:09:02 +00:00
Felipe Pena e516b7a964 - Fixed bug #53335 (pdo_firebird did not implement rowCount())
patch by: preeves at ibphoenix dot com
2010-11-18 01:24:00 +00:00
Pierrick Charron 6f7821a82d Remove unused variables 2010-11-17 17:55:18 +00:00
Pierre Joye 4ced44323d - test for NULL deref fix 2010-11-17 17:26:33 +00:00
Pierre Joye 7b27de9f0b - NULL deref fix, patch by Gustavo 2010-11-17 16:46:19 +00:00
Jani Taskinen d225fe4e58 - Fix test 2010-11-17 14:54:37 +00:00
Felipe Pena 5d2e201c3d - Fixed typo (reported by eyal.t at zend dot com) 2010-11-17 14:49:26 +00:00
Felipe Pena 7716873a5b - Updated QA and User note maintainers credits 2010-11-16 23:02:00 +00:00
Jérôme Loyet 404580d95c - fix (log with level < WARNING before daemonizing were not written to /dev/stderr) 2010-11-16 22:53:47 +00:00
Felipe Pena bbf58f9234 - Fixed bug #53319 (strip_tags() may strip '<br />' incorrectly) 2010-11-16 22:16:44 +00:00
Jérôme Loyet 5ddbeffc6f - Fixed #53310 (sparc < v9 won't is not supported) 2010-11-16 22:02:36 +00:00
Felipe Pena 49493e226d - Fixed bug #53323 (pdo_firebird getAttribute() crash)
patch by: preeves at ibphoenix dot com
2010-11-16 21:02:14 +00:00
Christopher Jones 2bc233e856 Improve test cross- DB version portability 2010-11-16 20:50:29 +00:00
Christopher Jones f819965513 Added missing news 2010-11-16 19:38:31 +00:00
Christopher Jones 2ea52b1fb4 Protect against null bytes in LOB filenames (rasmus) 2010-11-16 19:33:31 +00:00
Pierre Joye 4af7de49aa - fix build 2010-11-15 23:46:21 +00:00
Felipe Pena e6de920a27 - Fix wrong argument to read_property call 2010-11-15 18:48:48 +00:00
Gustavo André dos Santos Lopes 1045aa2a7c - Fixed bug #52820 (writes to fopencookie FILE* not commited when seeking the
stream).
2010-11-15 18:22:52 +00:00
Rasmus Lerdorf d91c4be0d6 ws fix 2010-11-15 09:04:27 +00:00
Pierre Joye f6b3d22218 - allow firebird header to be in the normal deps directory and restore firebird support on win (5.3.4+) 2010-11-14 22:40:30 +00:00
Jérôme Loyet 5ef0100b4d - extend the 'i-t' fpm argument to dump configuration file when called twice (-tt) 2010-11-14 22:22:07 +00:00
Jérôme Loyet c95477e729 - Fixed #52691 (allow multiple instance of FPM using a custom prefix) 2010-11-14 22:01:34 +00:00
Felipe Pena 6958cb4a14 - Added missing void arg checks 2010-11-14 18:40:08 +00:00
Felipe Pena 46983d532e - Add missing check 2010-11-14 01:38:52 +00:00
Jani Taskinen e0858b424a - Using ifelse() here is safer, also eases debugging generated configure. 2010-11-13 22:51:11 +00:00
Felipe Pena a0ccf0f14a - Fix the constant detection 2010-11-13 19:50:55 +00:00
Felipe Pena 8901635d73 - Fixed bug #53305 (E_NOTICE when defining a constant starts with __COMPILER_HALT_OFFSET__)
- Fixed a part of bug #53260 (the __COMPILER_HALT_OFFSET__ name is not shown in the E_NOTICE)
2010-11-13 18:46:11 +00:00
Derick Rethans bb1dbdf62c - Sync from HEAD. 2010-11-13 16:31:01 +00:00
Derick Rethans 28b41c811d - MFH: Added support for the ( and ) delimiters/separators to
DateTime::createFromFormat().
- Regenerated the parsers for HEAD and PHP_5_3.
2010-11-13 15:01:48 +00:00
Derick Rethans 9b4999881f - Don't show timezone if it wasn't found while parsing. 2010-11-13 14:57:47 +00:00
Jani Taskinen 47713462ce - WS 2010-11-13 11:07:38 +00:00
Jani Taskinen 0e72e5897e - Sync with trunk 2010-11-13 10:18:35 +00:00
Felipe Pena c095bec250 - Fixed bug #53136 (Invalid read on openssl_csr_new()) 2010-11-12 23:34:03 +00:00
Gustavo André dos Santos Lopes 3332c5be08 - Fixed bug #53297 (gettimeofday implementation in php/win32/time.c can return
1 million microsecs). (ped at 7gods dot org)
- Moved line out of order in NEWS.
2010-11-12 18:37:02 +00:00
Ulf Wendel b343748d56 Testing for the two new statistics 'bytes_received_real_data_normal' and 'bytes_received_real_data_ps' 2010-11-12 12:21:35 +00:00
Jérôme Loyet c28f44e409 - Fixed #52660 (custom process title for FPM) 2010-11-12 00:30:35 +00:00
Jérôme Loyet 5a416465a0 - Fixed #52692 (Added '-t/--test' to php-fpm to check and validate FPM conf file) 2010-11-11 23:27:15 +00:00
Jérôme Loyet da29092159 - Fixed bug #52693 (configuration file errors are not logged to stderr) 2010-11-11 22:48:46 +00:00
Jérôme Loyet 7bc07ff884 - get rid of ZLOG_STUFF code redundancy 2010-11-11 21:38:18 +00:00
Jérôme Loyet 8dd82c5fde - comment out fpm_php_set_fcgi_mgmt_vars to remove compilation warning 2010-11-11 21:30:55 +00:00
Jérôme Loyet 71a8b75c51 - remove useless check 2010-11-11 12:56:44 +00:00
Jérôme Loyet 8977fc8ace - add missing timer* macros (for solaris)
- ws
2010-11-11 12:49:11 +00:00
Jérôme Loyet d7e8aaea46 here come the new 2010-11-11 02:43:51 +00:00
Jérôme Loyet 0a1e29d74b - add "listen queue len" stat (thx to Andrei Nigmatulin) 2010-11-11 02:34:47 +00:00
Kalle Sommer Nielsen 4cc8073839 Added new constant; ZEND_MULTIBYTE to check whether PHP was compiled using --enable-zend-multibyte or not instead of sniffing phpinfo() (FR #52348) 2010-11-11 01:43:53 +00:00
Jérôme Loyet 7e56681670 - syntax and minor optimizations 2010-11-11 01:01:56 +00:00
Jérôme Loyet 07abcdc031 - don't call shutdown functions after child ends softly, let the master process call them 2010-11-10 23:54:14 +00:00
Christopher Jones f4b2664e2c Prepare for PECL OCI8 1.4.4 2010-11-10 19:08:13 +00:00
Christopher Jones 29bdf30880 Improve startup failure error messages 2010-11-10 18:59:56 +00:00
Christopher Jones 7a42845d80 Fixed bug #53284 (Valgrind warnings in oci_set_* functions) 2010-11-10 18:49:55 +00:00
Christopher Jones 2bf58d8c70 Improve test portability 2010-11-10 18:46:05 +00:00
Andrey Hristov 77d160772f Fix bad types, because zend_parse_xxx expect signed integers
for lengths, no matter how stupid this is :)
2010-11-10 13:57:09 +00:00
Adam Harvey 4df2980242 Fix line wrapping. 2010-11-09 14:54:10 +00:00
Adam Harvey 84dc845ff8 Fix bug #53279 (SplFileObject doesn't initialise default CSV escape character). 2010-11-09 14:53:23 +00:00
Moriyoshi Koizumi 89d372ba27 - Fix bug #53273 (mb_strcut() returns garbage with the excessive length parameter). 2010-11-09 03:23:04 +00:00
Felipe Pena 22f7998a0d - Fix the fix (wrong behavior) 2010-11-08 20:26:14 +00:00
Dmitry Stogov b01b2e6d0b Fixed WSDL loading using https through proxy 2010-11-08 11:34:32 +00:00
Patrick Allaert 817776d1b9 - Fixed tests not passing under windows because of the directory separator
difference (thanks Eyal Teutsch for reporting)
2010-11-08 09:29:15 +00:00
Adam Harvey 53544e36f2 Update the tests committed in r305098 (as part of the fix for bug #53226) to
use the PHP_MAXPATHLEN constant, as recommended by Pierre.
2010-11-08 09:14:48 +00:00
Gustavo André dos Santos Lopes c3557ba32e - Fixed the filter extension accepting IPv4 octets with a leading 0 as that
belongs to the unsupported "dotted octal" representation.
- Fixed bug #53236 (problems in the validation of IPv6 addresses with leading
  and trailing :: in the filter extension).
- Fixed bug #50117 (problems in the validation of IPv6 addresses with IPv4
  addresses and ::).
2010-11-08 04:36:15 +00:00
Jérôme Loyet f407fc4e01 - correct time comparison for determining the last idle child 2010-11-07 21:47:14 +00:00
Jérôme Loyet 0399b83ccb - change signal from SIGTERM to SIGQUIT for killing a child process by the dynamic process manager 2010-11-07 19:41:28 +00:00
Felipe Pena e6bef6735f - Fixed bug #52512 (Broken error handling in odbc_execute)
patch by: mkoegler at auto dot tuwien dot ac dot at
2010-11-07 18:13:53 +00:00
Felipe Pena 50863932a6 - Fixed bug #53248 (rawurlencode RFC 3986 EBCDIC support misses tilde char).
patch by: Justin Martin (frozenfire@php)
2010-11-07 12:59:22 +00:00
Felipe Pena 1db7472a73 - Coding standards 2010-11-06 18:35:38 +00:00
Felipe Pena f4927c28bc - Fixed bug #52732 (Docs say preg_match() returns FALSE on error, but it returns int(0))
patch by: slugonamission at gmail dot com
2010-11-06 18:32:10 +00:00
Felipe Pena 996f45b688 - Fixed bug #47199 (pg_delete() fails on NULL)
patch by: ewgraf at gmail dot com
2010-11-06 17:43:25 +00:00
Felipe Pena 7636635ec5 - Fixed bug #50579 (RegexIterator::REPLACE doesn't work) 2010-11-06 00:09:50 +00:00
Andrey Hristov 837391a9a7 two new stats 2010-11-05 20:07:34 +00:00
Gustavo André dos Santos Lopes 8342c36f09 - Renamed php_stream_rep_nonstand_mode to
php_stream_mode_sanitize_fdopen_fopencookie, made it not
  exported and movied it from php_streams.h to
  php_streams_int.h.
2010-11-05 18:53:48 +00:00
Adam Harvey b84e262f63 Fix bug #53226 (file_exists fails on big filenames). 2010-11-05 05:28:07 +00:00
Gustavo André dos Santos Lopes dd038a9c89 - Added CLEAN section to recently committed test. 2010-11-05 01:56:28 +00:00
Gustavo André dos Santos Lopes 68107ae1c3 - Fixed bug #53241 (stream casting that relies on fdopen/fopencookie fails
with streams opened with, inter alia, the 'xb' mode).
2010-11-05 01:29:08 +00:00
Pierre Joye 8efec79ffe - expose php_sys_(l)stat, doing will prevent me to have to provide pecl's builds for <5.3.3 and another set for 5.3.4+. Trunk remains the same, A(B/P)I can be broken there 2010-11-04 01:16:20 +00:00
Pierre Joye e61005f712 - fix type and silent warning 2010-11-03 21:50:03 +00:00
Pierre Joye 6c3ddc70ed - add stat support for zip:// 2010-11-03 21:48:08 +00:00
Pierre Joye 535033074a - add CVE 2010-11-03 20:22:08 +00:00
Etienne Kneuss 9d25e7ee7b Fixed covariance of return-by-ref constraints 2010-11-03 15:40:24 +00:00
Felipe Pena 21638aed88 - BFN 2010-11-03 01:46:52 +00:00
Felipe Pena 815d0e549b - Reverted fix for bug #51176 2010-11-03 01:35:26 +00:00
Felipe Pena 7b4cbadfce - Fixed config.m4 to complete the fix for bug #53141 (thanks Johannes) 2010-11-02 20:51:02 +00:00
Felipe Pena 7ded7577b2 - Fixed bug #53141 (autoload misbehaves if called from closing session)
patch by: ladislav at marek dot su
2010-11-02 18:34:56 +00:00
Ilia Alshanetsky a1632696a8 Fixed a possible double free in imap extension (Identified by Mateusz Kocielski). 2010-11-02 17:50:39 +00:00
Pierre Joye e547a0dfec - add CVE id 2010-11-02 15:33:49 +00:00
Jani Taskinen 309aefc7e7 - Fixed -g adding for gcc and g++ (former got it twice, latter not at all) 2010-11-02 09:58:08 +00:00
Arnaud Le Blanc 3ac257f344 MFH fixed bug #52784 (Race condition when handling many
concurrent signals)
2010-11-01 22:43:59 +00:00
Arnaud Le Blanc cd63986283 MFH Fix bug #52173 (ext/pcntl doesn't store/report errors)
(patch by nick dot telford at gmail dot com)
2010-11-01 20:22:23 +00:00
Derick Rethans 6e0f2daf65 - Updated to version 2010.15 (2010o) 2010-11-01 17:55:42 +00:00
Felipe Pena f4d15d8226 - Fixed bug #47643 (array_diff() takes over 3000 times longer than php 5.2.4) 2010-11-01 17:16:47 +00:00
Gustavo André dos Santos Lopes 231da1a5cb - Fixed bug #53198 (changing INI setting "from" with ini_set did not have any
effect)
#Made "from" a proper INI setting and bound it to a global variable.
#Previously, it was simply read from the hash table with the parsed ini file
#by using cfg_get_string (I wonder why this mechanism still exists...)
2010-10-29 15:29:15 +00:00
Andrey Hristov c10af225c4 - More features for the profiling, create aggregates and dump them
on file close.
- Also add a trace modifier to switch on and off the profiling.
- With additional compiler switch the profiling can be completely omitted,
of course it makes sense only when --enable-debug. Because otherwise
there is no tracing, thus no profiling.
- Added a fix for Windows for handling trace files on different devices
 (special handing of ':' )
2010-10-29 15:02:39 +00:00
Andrey Hristov cd6ea54deb gettimeofday for windows 2010-10-28 14:14:06 +00:00
Andrey Hristov 443bedf204 show tracing 2010-10-28 14:07:36 +00:00
Andrey Hristov 4c34cd9f38 fix windows debug build
better zlib detection
2010-10-28 13:46:54 +00:00
Gustavo André dos Santos Lopes db75ce41a3 - Fixed bug #49687 (utf8_decode vulnerabilities and deficiencies in the number
of reported malformed sequences). (Gustavo)
#Made a public interface for get_next_char/utf-8 in trunk to use in utf8_decode.
#In PHP 5.3, trunk's get_next_char was copied to xml.c because 5.3's
#get_next_char is different and is not prepared to recover appropriately from
#errors.
2010-10-27 18:13:25 +00:00
Gustavo André dos Santos Lopes ee80871a15 - Fixed bug #53180 (post_max_size=0 not disabling the limit when the content
type is application/x-www-form-urlencoded or is not registered with PHP).
2010-10-27 14:56:51 +00:00
Gustavo André dos Santos Lopes b5b4f94a4c - Fixed ReflectionProperty::isDefault() giving a wrong result for properties
obtained with ReflectionClass::getProperties().
2010-10-26 18:47:10 +00:00
Gustavo André dos Santos Lopes 0086bc8a96 - Implemented request #44164, zlib.output_compression is now implicitly
disabled when the header "Content-length" is set.
#One could argue that any output handler could change the size of the
#response, so this exception for zlib.output_compression is an
#inconsistency. However, zlib.output_compression is presented as a
#performance setting, whose value should have no effect on the
#correctness of the scripts. This was not the case. Setting the
#header "content-length" and enabling zlib.output_compression was
#a recipe for infringing section 4.4 of RFC 2616.
2010-10-26 02:16:21 +00:00
Andrey Hristov 762a1b2d26 rename and remove usage of inttypes.h, not needed 2010-10-25 13:44:11 +00:00
Gustavo André dos Santos Lopes 384cd8cda5 - Small optimization of the fix of bug #53071. It's not necessary to destroy
the debug info as it's not holding references anymore (the fix removed
  the refcount increments).
2010-10-25 02:03:20 +00:00
Gustavo André dos Santos Lopes 5721132c29 - Fixed bug #53071 (SPLObjectStorage defeats gc_collect_cycles). 2010-10-25 01:41:54 +00:00
Pierre Joye 3cb6a460a6 - fix Isotopp 2010-10-24 21:51:54 +00:00
Felipe Pena eabf03f436 - BFN 2010-10-24 14:05:10 +00:00
Felipe Pena 6887b97a8d - Fixed bug #53144 (SplObjectStorage::removeAll()) 2010-10-24 14:03:07 +00:00
Andrey Hristov 924bb78167 profiling in trace mode 2010-10-22 15:46:26 +00:00
Andrey Hristov 4cedb6d08a last piece to enable trace logging on windows 2010-10-22 14:34:33 +00:00
Andrey Hristov f7c44c8c4d enable debug logging on windows, in debug builds, of course 2010-10-22 14:12:45 +00:00
Ilia Alshanetsky 8a2a6dbe21 Upgraded bundled sqlite to version 3.7.3 2010-10-20 19:27:34 +00:00
Pierre Joye 8c5921bfb8 - update #52929 and zip NULL deref 2010-10-19 09:56:59 +00:00
Pierre Joye 6ab767262c - fix Fixed NULL pointer dereference in ZipArchive::getArchiveComment, (CVE-2010-3709), report&patch from Maksymilian Arciemowicz 2010-10-19 09:55:36 +00:00
Adam Harvey 6a289f4d10 Fix bug #53089 (php.ini should use portable example of find) by using POSIX
compliant syntax in the suggested find command for cleaning up session files in
the shipped php.ini files.
2010-10-18 02:10:29 +00:00
Felipe Pena 946f95c0fc - Fixed bug #53070 (Calling enchant_broker_get_dict_path before set_path crashes php) 2010-10-16 17:52:01 +00:00
Gustavo André dos Santos Lopes 3ab0b74de9 - Updated NEWS to note fix of bug #53006 now that it's confirmed it's fixed. 2010-10-15 23:54:24 +00:00
Gustavo André dos Santos Lopes a3cef7b435 - Three tests were "broken" by rev #304404, not two. Commit the change
to remaining one.
2010-10-14 19:33:12 +00:00
Gustavo André dos Santos Lopes 30d6cc8919 - Fixed get_next_char(), used by htmlentities/htmlspecialchars, accepting
certain ill-formed UTF-8 sequences.
2010-10-14 19:14:06 +00:00
Gustavo André dos Santos Lopes c99251f87e - [DOC] Reverted rev #304382 and rev #304380, as I figured out a way to
fix the erratic behavior without breaking backwards compatibility. Namely,
  $offset retains SEEK_SET behavior but actually SEEK_CUR is passed to
  _php_stream_seek, if possible, by moving the offset stream->position bytes.
- Addresses bug #53006.
2010-10-14 03:15:15 +00:00
Adam Harvey db633fb71d Fix vim marker folds. 2010-10-13 09:23:39 +00:00
Dmitry Stogov b88f7753a1 Fixed bug #52939 (zend_call_function does not respect ZEND_SEND_PREFER_REF) 2010-10-13 08:51:39 +00:00
Gustavo André dos Santos Lopes 14a54b903e - Fixed forward stream seeking emulation in streams that don't support seeking
in situations where the read operation gives back less data than requested
  and when there was data in the buffer before the emulation started. Also made
  more consistent its behavior -- should return failure every time less data
  than was requested was skipped.
- Small performance improvement by correcting off-by-one error that generate an
  invalid call to the seek handler or read handler. in _php_stream_seek.
2010-10-13 03:13:29 +00:00
Dmitry Stogov d46dcd301e Added test 2010-10-12 07:38:36 +00:00
Gustavo André dos Santos Lopes 99b613cbc8 - Added a 3rd parameter to get_html_translation_table. It now takes a charset
hint, like htmlentities et al.
- Fixed bug #49407 (get_html_translation_table doesn't handle UTF-8).
- Fixed bug #25927 (get_html_translation_table calls the ' &#39; instead of
  &#039;).
- Fixed tests for get_html_translation_table and unified the Windows and
  non-Windows versions of the tests.
2010-10-12 02:51:11 +00:00
Gustavo André dos Santos Lopes 40c3aefafb - Removed redundant local variable in dns_get_record.
- (5.3) Fixed bug in the Windows implementation of
  dns_get_record, where the two last parameters wouldn't be
  filled unless the type were DNS_ANY (Gustavo).
2010-10-11 03:07:03 +00:00
Gustavo André dos Santos Lopes 4e2fd7eeba - Fixed a typo in rev #304208 (24 instead of 34/'"').
- Improved the test bug53021.phpt to reflect other fixes in rev #304208.
- Updated NEWS to reflect other fixes in rev #304208.
2010-10-08 17:27:19 +00:00
Gustavo André dos Santos Lopes 485a094334 - Fixed bug #53021 (In html_entity_decode, failure to convert numeric entities with ENT_NOQUOTES and ISO-8859-1). 2010-10-08 16:19:58 +00:00
Andrey Hristov 93d7715e7b new collations 2010-10-08 09:15:31 +00:00
Felipe Pena f7582fc43b - Added bison 2.4.3 version to the bison version list 2010-10-07 21:44:41 +00:00
Andrey Hristov 2d2d6f84ba fix some uninitialized variables. also fix shadowing of global symbols 2010-10-07 13:49:00 +00:00
Ilia Alshanetsky a4252ab2be Fixed extrenous warning inside openssl_encrypt() for cases where iv not provided, but algo does not require an iv 2010-10-07 12:32:00 +00:00
Gustavo André dos Santos Lopes 8d34fe0d22 - Fixed test for bug #50590 on systems with 64-bit longs. 2010-10-06 17:05:05 +00:00
Andrey Hristov 1f86f6be31 here comes the news 2010-10-06 11:12:53 +00:00
Andrey Hristov 4f62c099cd Fix for Bug #52686 mysql_stmt_attr_[gs]et arg. points to incorrect type 2010-10-06 11:11:02 +00:00
Andrey Hristov 1cca9d4bf1 more variable hiding fixes 2010-10-06 07:09:37 +00:00
Andrey Hristov 062ddaa700 fix shadowing of parameters 2010-10-06 06:08:55 +00:00
Kalle Sommer Nielsen 58a15c2cf5 Update copyright year for the license 2010-10-05 22:58:19 +00:00
Andrey Hristov 82de444f9a rename parameter name - should not shadow the global symbol alloca 2010-10-05 17:20:00 +00:00
Andrey Hristov eb2908c3f7 two more compiler warnings fixed - size does matter 2010-10-05 17:10:47 +00:00
Andrey Hristov 25e84b6a23 Rename a method so it doesn't clash with a global symbol - a function
Fix compiler waring by extening the type of a variable
2010-10-05 17:03:50 +00:00
Andrey Hristov 3daf54ffa0 Fix compiler warnings - on 32bit size_t is smaller than uint64_t, although
we will never hit this the compiler should be happy.
2010-10-05 16:54:14 +00:00
Andrey Hristov 548661d96d rename parameter, should not conflict with global symbol -
the socket function
2010-10-05 16:27:49 +00:00
Andrey Hristov e97a07ae9e remove trailing commas in enums 2010-10-05 14:56:49 +00:00
Ulf Wendel bd73903efb Fix test: third parameter can be false. 2010-10-05 14:41:08 +00:00
Antony Dovgal 421b86ed5e fix bug #50345 (nanosleep not detected properly on some solaris versions) 2010-10-05 13:43:35 +00:00
Ulf Wendel ccaff0e994 Greetings from SunCC.
ext/mysqli/mysqli_driver.c", line 127|128|129: warning: syntax error:  empty declaration
2010-10-05 12:42:53 +00:00
Dmitry Stogov 1b60eb8813 Fixed bug #44248 (RFC2616 transgression while HTTPS request through proxy with SoapClient object). 2010-10-05 11:43:59 +00:00
Dmitry Stogov 455db21e06 Fixed bug #51008 (Zend/tests/bug45877.phpt fails) 2010-10-05 11:28:56 +00:00
Andrey Hristov bf7e6f930c add some safe casts 2010-10-05 11:08:21 +00:00
Patrick Allaert bf6440d00a Fixed typo in tests (thx Eyal) 2010-10-05 10:42:13 +00:00
Andrey Hristov c4e145b0bc fixing more types 2010-10-05 10:30:00 +00:00
Kalle Sommer Nielsen 33c99f9a44 Fixed constness compiler warning in pdo_mysql 2010-10-05 09:58:15 +00:00
Kalle Sommer Nielsen efe22e3bfa Fix constness warnings 2010-10-05 09:48:07 +00:00
Kalle Sommer Nielsen 87edd143ed Fixed compiler warnings in mysqli
- mysqli.c: Fix unused variables, they are only used in non-mysqlnd mode
 - mysqli_api.c (PHP_5_3 only): Fix constness, add_property_string expects a char *, not a const char *
 - mysqli_prop.c: Cast to long, as its below the LONG_MAX and therefore safe
 - mysqli_result_iterator.c: Cast to ulong as the iterator member expects that rather than a my_longlong

# In trunk only warnings regarding the zend_property_info 
# structure is present and PHP_5_3 is warning free now
2010-10-05 09:40:36 +00:00
Andrey Hristov df2261df2a fix types 2010-10-05 08:56:21 +00:00
Ulf Wendel 234181f690 Fix warnings
ext\mysqlnd\mysqlnd_result_meta.c(57) : warning C4090: 'initializing' : different 'const' qualifiers
ext\mysqlnd\mysqlnd_result_meta.c(64) : warning C4090: 'initializing' : different 'const' qualifiers
ext\mysqli\mysqli_report.c(50) : warning C4013: 'php_mysqli_throw_sql_exception' undefined; assuming extern returning int
2010-10-05 08:29:54 +00:00
Andrey Hristov 4c88033aa2 fix recent TSRM build break, with --enable-debug 2010-10-05 08:17:33 +00:00
Gustavo André dos Santos Lopes b3a3c8f7a6 - Moved ucgendat.c to a separate directory and included the
OpenLDAP license there, as required by the license itself.
2010-10-05 02:34:35 +00:00
Gustavo André dos Santos Lopes 7e61cffb0d - Fixed bug #52981 (Unicode casing table was out-of-date).
Updated with UnicodeData-6.0.0d7.txt and included the
  source of the generator program with the distribution.
#The replaced tables, generated circa 2002, seem to reflect
#Unicode 3.2. I was unable to generate the same property
#offsets with Unicode 3.2 data, but all the tests I made
#indicate php_unicode_is_prop() is returning the correct
#values. The replaced file merely says it used a "modified
#version" of ucgendat, which is not very helpful. The results
#I got were not significantly different, only slightly higher
#offsets at two properties, which were carried over to the
#subsequent properties.
#I was, however, able to replicate precisely the casing table.
#The extent of the "modifications" besides omitting most of
#the tables, a slightly different layout and the casing table
#offsets having been multiplied by 3 is unclear.
#The test suite showed no regressions; however, it's very poor
#in testing the modified portion of the extension.
2010-10-05 01:54:17 +00:00
Kalle Sommer Nielsen 54624f9902 We do not need this TSRMLS_FETCH() call as we do not use any TSRM stuff in here, so we can get
a minor boost here in ZTS mode.
2010-10-04 21:04:25 +00:00
Andrey Hristov a4ad111454 fix two more warnings 2010-10-04 14:52:14 +00:00
Andrey Hristov 9f73a4e045 add some safe casts - lower the number of warnings by 2 2010-10-04 14:12:31 +00:00
Andrey Hristov 4c63a2232d Fix const-ness 2010-10-04 13:54:30 +00:00
Ulf Wendel 5aca10ee13 Trying to fix compiler warnings (on Windows). 2010-10-04 13:36:23 +00:00
Andrey Hristov 159ed311cc Even better patch 2010-10-04 12:59:29 +00:00
Andrey Hristov cacd5ad924 don't define twice the macro on some platforms 2010-10-04 12:41:12 +00:00
Ulf Wendel 1f9a7fd758 Fixing compiler warning. 2010-10-04 10:58:05 +00:00
Ulf Wendel ee2a82e327 Fixing "ext/mysqlnd/mysqlnd.h", line 287: warning: syntax error: empty declaration" 2010-10-04 10:51:44 +00:00
Ulf Wendel 122179478a Next one... ext/mysqli/mysqli_fe.c", line [many]: warning: syntax error: empty declaration 2010-10-04 10:43:21 +00:00
Ulf Wendel 4113fad4ec Fixing compiler warning "ext/mysqli/mysqli_prop.c", line [...]: warning: syntax error: empty declaration" 2010-10-04 10:40:16 +00:00
Ulf Wendel 71bbb24ff0 Sorry again, nothing but removal of white space from the end of the lines.
- fix compile warning "ext/mysql/php_mysql.c:640:11: warning: extra tokens at end of #ifdef directive"
2010-10-04 10:08:10 +00:00
Ulf Wendel 2d925fb216 Sorry for the commit but compiler warnings are annoying and so are white spaces at the end of a line, if one uses an editor which removes them on save and diff's get blown
up by white space changes...

Changes: 
- remove end of line white space
- fix compiler warning "ext/mysqli/mysqli_priv.h:156:27: warning: no newline at end of file"
- fix compiler warning "ext/mysqli/mysqli_fe.h:135:25: warning: no newline at end of file"
- fix compiler warning "ext/mysqli/mysqli.c:896:11: warning: extra tokens at end of #ifdef directive"
2010-10-04 10:02:58 +00:00
Gustavo André dos Santos Lopes 817c28c867 - Implemented FR #50692, not uploaded files don't count towards
max_file_uploads limit.
- As a side improvement, temporary files are not opened for
  empty uploads and, in debug mode, 0-length uploads.
2010-10-04 01:27:33 +00:00
Felipe Pena 090a9b3331 - Fixed bug #52971 (PCRE-Meta-Characters not working with utf-8)
#   In  PCRE,  by  default, \d, \D, \s, \S, \w, and \W recognize only ASCII
#       characters, even in UTF-8 mode. However, this can be changed by setting
#       the PCRE_UCP option.
2010-10-03 16:01:38 +00:00
Gustavo André dos Santos Lopes 4b0927b042 - Fixed a small mistake in the fix for bug #50953 that made connection timeouts not be detected as such. 2010-10-02 18:32:20 +00:00
Dmitry Stogov 4d8503a212 Fixed bug #52879 (Objects unreferenced in __get, __set, __isset or __unset can be freed too early). (mail_ben_schmidt at yahoo dot com dot au, Dmitry) 2010-10-01 09:49:20 +00:00
Ulf Wendel bc6e920ebc Fix leak with persistent connections when using mysqli.default_host is used 2010-10-01 08:54:16 +00:00
Stanislav Malyshev b55d4ecb41 Fix bug #52906 gmp_mod returns negative result when non-negative is expected 2010-10-01 00:12:23 +00:00
Andrey Hristov 60327d87a7 Plug a leak in mysqli when in the same script
a pconn is reused.
Call end_psession earlier - so will mysqlnd and
the plugins free data earlier.
2010-09-30 18:10:03 +00:00
Dmitry Stogov 5c6f0ebeab Prevented crash in GC because of incorrect reference counting 2010-09-30 14:11:51 +00:00
Adam Harvey 104bf57ae7 Loosen the valgrind version check slightly in run-tests.php so that it works
with the packaged valgrind in Ubuntu 10.04.
2010-09-30 11:16:45 +00:00
Adam Harvey 5f9956397f Fixed bug #52941 (The 'iconv_mime_decode_headers' function is skipping
headers).
2010-09-30 11:04:21 +00:00
Gustavo André dos Santos Lopes 0db999a94f - Fixed bug #52944 (Invalid write on second and subsequent reads with an inflate filter fed invalid data). 2010-09-29 18:58:58 +00:00
Andrey Hristov 3113744c57 Fix a problem that leads to leaks in plugins that
use stmt local data - no free is called for statements
that are over-prepared
2010-09-29 13:18:07 +00:00
Andrey Hristov 517fd63c32 fix the test 2010-09-29 11:40:57 +00:00
Felipe Pena a5459c09c9 - Fixed bug #52947 (segfault when ssl stream option capture_peer_cert_chain used) 2010-09-29 01:25:35 +00:00
Andrey Hristov 22d73027d0 add another hook, maybe the last one, for MYSQLND_STMT, which
was missed before
2010-09-28 14:36:18 +00:00
Pierre Joye 6bae8fbd9c - Fixed possible flaw in open_basedir (CVE-2010-3436) 2010-09-28 13:30:30 +00:00
Pierre Joye edb4351004 - Fixed possible flaw in open_basedir (CVE-2010-3436) 2010-09-28 13:29:33 +00:00
Felipe Pena 2cd1661e2d - Fixed bug #52931 (strripos not overloaded with function overloading enabled) 2010-09-27 23:09:00 +00:00
Derick Rethans 761cc30055 - Updated to version 2010.13 (2010m) 2010-09-27 13:57:42 +00:00
Andrey Hristov 42a80fac8c Fixed bug #45921 (Can't initialize character set hebrew) 2010-09-27 12:35:59 +00:00
Andrey Hristov b080cfcc71 Fix the value, it was bumped 2010-09-27 11:23:01 +00:00
Adam Harvey 2d4c7b4033 Fix bug #52929 (Segfault in filter_var with FILTER_VALIDATE_EMAIL with large
amount of data).
2010-09-27 07:08:04 +00:00
Pierre Joye 4839387edd - fix bug #52926, zlib fopen wrapper does not use the context 2010-09-26 20:46:54 +00:00
Adam Harvey fc2ed1b5d0 MFH: fix phar phpinfo() tests. 2010-09-24 12:13:33 +00:00
Andrey Hristov 216effe4f5 WS fixes 2010-09-23 16:03:22 +00:00
Ulf Wendel 8bb124394b Let's try not to have 'uft8'-only tests and avoid setting the charset upon connect. I've changed the tests to make no assumptions on the server charset setting. var_dump()/EXPECTF tests got replaced with dynamic tests which try to take the current charset into account. 2010-09-23 15:08:43 +00:00
Ulf Wendel 389965f1de Merge from head: do not use deprecated function aliases. The test logic is unchanged. 2010-09-23 14:59:13 +00:00
Adam Harvey 107f916322 Fix up the vim folds in phar_object.c and add a note that the two prototypes
before Phar::__construct() are actually valid and not a mistake, per bug
#52909.
2010-09-23 04:41:14 +00:00
Pierre Joye f1d2e1453c - Fix #52908, fix declaration 2010-09-22 21:28:37 +00:00
Andrey Hristov bdaec773b5 Unify, force one charset at connect, thus fixing
test failures because different servers have different
system charsets.
2010-09-22 18:25:33 +00:00
Ulf Wendel 7f0ec2a127 Test update for sql_mode = ansi 2010-09-22 15:22:22 +00:00
Ulf Wendel 841c151b64 Test update for sql_mode = ANSI 2010-09-22 15:16:07 +00:00
Andrey Hristov ff27146950 small macro fix 2010-09-22 14:54:43 +00:00
Andrey Hristov 86c1364695 fix for bug 52891 - optimize a bit 2010-09-22 14:26:43 +00:00
Andrey Hristov b962a566af hier comes the news 2010-09-22 11:40:20 +00:00
Andrey Hristov 1de4cfb791 Fix for
Bug #52891 Wrong data inserted with mysqli/mysqlnd when using bind_param,value>LONG_MAX
2010-09-22 11:38:49 +00:00
Andrey Hristov 047f0e4d88 update tests 2010-09-22 11:09:29 +00:00
Ulf Wendel 2ff0c392e7 Trying to pimp gcov.php.net code coverage tests.. trying to cover mysqlnd compress code with a standard test run 2010-09-20 19:01:13 +00:00
Ulf Wendel 7f6d8e53fd Align test to the style used in the other tests 2010-09-20 18:26:11 +00:00
Ulf Wendel 1a40f20729 No reason not to run the tests with libmysql. Its long, long ago that pconnect has been a mysqlnd only feature 2010-09-20 17:26:39 +00:00
Ilia Alshanetsky 9aafc5d1c6 Fixed a compiler warning 2010-09-20 12:48:27 +00:00
Ulf Wendel c30edd027f Dont be strict on error messages, they can vary by server version 2010-09-20 09:04:48 +00:00
Andrey Hristov 531085785b add test case for 52891 2010-09-20 09:02:31 +00:00
Pierre Joye 63883d4970 - not needed here anymore 2010-09-18 14:54:40 +00:00
Ulf Wendel 2d656381f8 Skip if PDO_SQLITE is not available 2010-09-17 17:11:21 +00:00
Ulf Wendel fe726b1beb Remove OS dependent directory separator from EXPECT 2010-09-17 16:40:02 +00:00
Pierre Joye 88117e6128 - restore VOLUME_NAME_NT and VOLUME_NAME_DOS definition, thx Andrey for the headup 2010-09-17 11:34:49 +00:00
Pierre Joye 064578114f - WS 2010-09-16 19:15:26 +00:00
Pierre Joye 664f06616a - fix news 2010-09-15 16:59:57 +00:00
Andrey Hristov 17ae7c1659 remove unneeded proxy function _mysqlnd_restart_psessoin 2010-09-15 12:23:45 +00:00
Andrey Hristov d99ee78503 Remove unneeded proxy function _mysqlnd_end_psession 2010-09-15 12:11:33 +00:00
Adam Harvey 416240947b Fix bug #52849 (GNU MP invalid version match). 2010-09-15 10:51:55 +00:00
Ulf Wendel 0dc0d76854 Fix test 2010-09-15 08:20:15 +00:00
Felipe Pena 09ca429157 - Fixed bug #52843 (Segfault when optional parameters are not passed in to mssql_connect) 2010-09-15 02:12:46 +00:00
Andrey Hristov fc2143b993 unify magic quotes handling. Also fix a problem which
resulted in a longjmp in debug PHP,because of usage of
zval that is NULL in a hash context.
2010-09-14 16:09:42 +00:00
Jérôme Loyet 8c1582c9ad - remove a memory leak (missing efree()) 2010-09-14 15:33:43 +00:00
Johannes Schlüter 0631d2c59d - Don't be silent on bailout 2010-09-14 14:26:37 +00:00
Adam Harvey 877a6f92f0 Fix bug #52827 (cURL leaks handle and causes assertion error (CURLOPT_STDERR)).
Patch by Gustavo.
2010-09-14 10:58:59 +00:00
Pierre Joye 992991fe1b - fix #48831 php -i has different output to php --ini 2010-09-14 10:36:21 +00:00
Adam Harvey 1f06a6a4e8 Fix English in the error message emitted when json_decode() is called with
depth <= 0.
2010-09-14 03:46:28 +00:00
Kalle Sommer Nielsen 4119b09a1a Fixed bug #52772 (var_dump() doesn't check for the existence of get_class_name before calling it) 2010-09-13 20:14:18 +00:00
Pierre Joye f4da90705b - use php_sys_sat 2010-09-13 11:17:40 +00:00
Pierre Joye 25ac985422 - ws 2010-09-13 11:06:18 +00:00
Pierre Joye 65942d343f - sanity check for the path length and don't treat UNC as local path (no functional change, only less ops) 2010-09-13 10:58:18 +00:00
Pierre Joye 013727e1c7 - MFH 2010-09-13 10:30:21 +00:00
Pierre Joye e5323bde9a - silent warning 2010-09-13 10:28:45 +00:00
Pierre Joye ffd60af473 - use php_sys_lstat 2010-09-13 10:27:55 +00:00
Pierre Joye eafd04d172 - use php_sys_readlink 2010-09-13 09:30:07 +00:00
Pierre Joye 3a2f5c2219 - WS 2010-09-13 09:08:42 +00:00
Adam Harvey a7da07a15f Fix bug #52826 (phpinfo is incorrect for bzip2 stream wrapper). 2010-09-13 07:41:39 +00:00
Pierre Joye d97c07c265 - remove dummy wrapper for readfile 2010-09-11 19:07:43 +00:00
Felipe Pena 6ca2ea7109 - Fixed bug #49215 (make fails on glob_wrapper) 2010-09-10 21:33:50 +00:00
Pierre Joye 20944e2516 - use php_sys_readlink 2010-09-10 19:25:56 +00:00
Pierre Joye cd727b4e9a - remove 'UNC' from the target 2010-09-10 19:21:02 +00:00
Pierre Joye 77d307ccbf - open_basedir symlink support for Windows 2010-09-10 17:45:13 +00:00
Pierre Joye 2b04364852 - Implement bug #51804, splFileInfo::getLinkTarget() on Windows 2010-09-10 14:17:40 +00:00
Pierre Joye 391ff7682c - add php_sys_readlink 2010-09-10 14:01:44 +00:00
Adam Harvey 6e06a45f24 Fix bug #52802 (Out-of-date comment for
file_get_contents/php_stream_copy_to_mem) by updating the relevant comments.
2010-09-10 03:08:05 +00:00
Felipe Pena 03df7fce82 - Fixed test 2010-09-09 21:46:29 +00:00
Adam Harvey 97f6da74a1 Fixed bug #52744 (cal_days_in_month incorrect for December 1 BCE). Original
patch by gpap at internet dot gr.
2010-09-09 06:41:23 +00:00
Adam Harvey bcea4e69bb Fix bug #52786 (PHP should reset section to [PHP] after ini sections). Patch by
Fedora at famillecollet dot com.
2010-09-09 05:11:05 +00:00
Adam Harvey 7a2c4afa91 Fix bug ordering in NEWS. 2010-09-09 05:08:58 +00:00
Pierre Joye abd1af951c - fix the fix for bug #52323 2010-09-08 11:51:11 +00:00
Pierre Joye b310ce9ccc - WS 2010-09-08 10:26:59 +00:00
Pierre Joye ce82e028b2 - Fix bug #52323, return value of php_network_connect_socket should be set even if the caller does not care about the error_string 2010-09-08 10:25:40 +00:00
Pierre Joye 266ff49a9a - Fix #50524, proc_open should respect cwd as it does on other platforms 2010-09-08 08:34:57 +00:00
Jérôme Loyet 9a1623dc5f - remove FPM specific version which is irrelevant since FPM integration into core. 2010-09-07 22:03:43 +00:00
Jérôme Loyet c725c054d6 - Fixed bug #52498 (libevent was not only linked to php-fpm) 2010-09-07 21:12:28 +00:00
Pierre Joye f696aece3f - fix bug #50953, socket will not connect to IPv4 address when the host has both ipv4 and ipv6 addresses 2010-09-07 09:47:36 +00:00
Pierre Joye c286d482aa - links related fixes 2010-09-06 14:54:43 +00:00
Pierre Joye 80ddb8d95c - fix bug #52260, catch all DNS not found error 2010-09-06 10:57:42 +00:00
Pierre Joye 4275e7428b - timeval element are always 32bit long on Windows 2010-09-06 10:39:26 +00:00
Pierre Joye 6c08709bd6 - kill warning 2010-09-06 10:28:04 +00:00
Pierre Joye 329cab2942 - restore credits, fix 5.3 as well, aka do it right /cc Deric 2010-09-05 14:38:35 +00:00
Derick Rethans d30323b867 - Clean up the generated tmp-php.ini after make test has run. 2010-09-05 12:29:47 +00:00
Rasmus Lerdorf 8022e383ff This incorrect contraction started to get on my eyes after I saw it for the
87th time while struggling with an annoying SOAP service.
2010-09-03 22:24:08 +00:00
Ulf Wendel 4789901728 Test for http://bugs.php.net/52221. Test will fail with mysqlnd but should pass with libmysql. 2010-09-03 14:20:32 +00:00
Dmitry Stogov c7b95db5ab Fixed GC bug 2010-09-03 09:27:47 +00:00
Ulf Wendel 48814f96ef Fix test failure. Add new test for MYSQLI_OPT_INT_AND_FLOAT_NATIVE mysqlnd feature. 2010-09-02 14:57:38 +00:00
Pierre Joye edfe2e11db - add it for 5.3 as well 2010-09-02 10:32:32 +00:00
Stanislav Malyshev a54ac71371 Fix bug #50590 - IntlDateFormatter::parse result is limited to the integer range 2010-09-01 20:34:59 +00:00
Andrey Hristov 292785ed61 fix build on windows, seems this macro is not defined 2010-09-01 16:54:20 +00:00
Andrey Hristov 8220c2e4ce OPT_COMPRESS support for mysqlnd_conn::set_client_option
To be used by mysqli_options
2010-09-01 14:47:36 +00:00
Pierre Joye 13fd8fcded - WS 2010-09-01 10:16:48 +00:00
Pierre Joye 87bf415853 - sb needed only in safemode 2010-09-01 10:13:46 +00:00
Pierre Joye 6396a3272c - add lstat support for Windows 2010-09-01 09:49:53 +00:00
Jérôme Loyet 6b2b7046ed - Fixed bug #52725 (gcc builtin atomic functions were sometimes used when they were not available). 2010-09-01 08:17:18 +00:00
Jérôme Loyet 5fd50c99cb - add 'max children reached' to the FPM status page. It shows how many times
a pool has reached the max_children parameter.
2010-08-31 14:49:16 +00:00
Ulf Wendel d27642fece PHP has changed (undefined) behaviour from 5.3.2 to 5.3.3: ->{} = , which seems to have been never an officially supported syntax and have never been a valid property name, is no longer allowed and PHP bails. 2010-08-31 14:43:02 +00:00
Timm Friebe c37b0c690a - MFT: Add ".so" suffix to checks on libsybct[64] bundles
# See patch by royanee at yahoo dot com @ bug #45357
2010-08-31 12:28:30 +00:00
Jérôme Loyet cbd21afae9 - Add libevent version to the startup debug log in FPM. 2010-08-31 09:41:04 +00:00
Jérôme Loyet 0605d5f309 - Changed listen.backlog in the FPM configuration file to default to 128
instead of -1 (except on FreeBSD and OpenBSD). This is the same value 
  as the one used in the cgi sapi. This patch completes revision 302725.
2010-08-31 09:33:53 +00:00
Felipe Pena c0840f18f3 - Fixed crash on non-Windows build 2010-08-30 21:34:54 +00:00
Andrey Hristov 77d650908d here comes the news 2010-08-30 18:13:28 +00:00
Andrey Hristov 72bef34918 Fix for MySQL Bug #49406
Binding params doesn't work when selecting a date inside a CASE-WHEN
(http://bugs.mysql.com/bug.php?id=49406)
The MySQL server sends MYSQL_TYPE_NEWDATE values as clear text, even
when PS are used and thus the binary protocol are used. Changing the
handler for the type.
2010-08-30 18:10:23 +00:00
Pierre Joye c55632007e - fix possible leak and error while fetching PHPRC 2010-08-30 17:05:56 +00:00
Ulf Wendel f671ad6275 Adding MYSQLI_OPT_SSL_VERIFY_SERVER_CERT for use with mysqli_options(). 2010-08-30 16:59:10 +00:00
Pierre Joye 71966d1e5a - WS 2010-08-30 16:52:48 +00:00
Derick Rethans b8837a79b2 - Tests for bug #52342 (DateTime setIsoDate results in wrong timestamp). 2010-08-30 16:48:21 +00:00
Derick Rethans adbf9e766e - Added test file that I forgot to commit. 2010-08-30 16:47:46 +00:00
Derick Rethans bb8ec8d629 - Fixed bug #52430 (date_parse parse 24:xx:xx as valid time). (Derick) 2010-08-30 16:40:29 +00:00
Derick Rethans aa82af78e4 - Fixed bug #52454 (Relative dates and getTimestamp increments by one day) 2010-08-30 16:25:52 +00:00
Derick Rethans 83a2d6e96e - Test for (non-)bug #52577. 2010-08-30 15:40:36 +00:00
Derick Rethans 550e18eaed - Added test for bug #46874 (same as #52668). 2010-08-30 15:35:41 +00:00
Derick Rethans bd184cc572 - Fixed bug #52668 (Iterating over a dateperiod twice is broken). 2010-08-30 15:32:09 +00:00
Jérôme Loyet a7057e4e49 - only one process (for all pools) could be killed by the 'dynamic' process manager. Now it's one process per pool which can be killed by the 'dynamic' process manager.
- rename nonsense variable (i)
2010-08-30 15:21:31 +00:00
Ulf Wendel d0e7e5aa2a If you add functions to the PDO core, take care not to break other PDO drivers tests, document the function and provide a function test for the PDO core to check your default/fallback implementation. 2010-08-30 09:20:48 +00:00
Ilia Alshanetsky a12d2bf747 Fixed a compiler warning 2010-08-27 19:43:08 +00:00
Pierre Joye 3c3ddb39b4 - WS 2010-08-27 10:09:52 +00:00
Andrey Hristov d9f50d95e3 Add proper magic_quotes_runtime support for mysqlnd, but
in mysqli, so we don't need to tamper myslqnd.
magic_quotes_runtime are deprecated and not existant in 5.4, thus
only fixing in the branch.
2010-08-26 14:51:58 +00:00
Pierre Joye a5e51efff8 - Symlink resolution fails when target is a DFS path 2010-08-26 14:23:17 +00:00
Ulf Wendel 6338f99d52 Test for http://bugs.mysql.com/bug.php?id=49406, Binding params doesn't work when selecting a date inside a CASE-WHEN 2010-08-26 13:35:20 +00:00
Felipe Pena 8fba11c57b - Fixed bug #52699 (PDO bindValue writes long int 32bit enum) 2010-08-25 22:03:03 +00:00
Andrey Hristov 07986a53e3 here comes the news 2010-08-25 15:07:34 +00:00
Andrey Hristov ab778e7414 Fix for bug #52221 Misbehaviour of magic_quotes_runtime (get/set)) 2010-08-25 15:06:47 +00:00
Andrey Hristov 7a83093a3b fix the build. two mysqli functions were missing after
recent commit - set_charset and get_charset
2010-08-25 15:02:02 +00:00
Pierre Joye adcf926b80 - CVE # for mops 2010-24 2010-08-25 14:27:39 +00:00
Adam Harvey c783495edf Fixed bug #52681 (mb_send_mail() appends an extra MIME-Version header). 2010-08-25 06:07:22 +00:00
Jérôme Loyet f9c6bb1ad8 - Fixed bug #52674 (FPM Status page returns inconsistent Content-Type headers). 2010-08-23 20:40:44 +00:00
Pierre Joye 411d090895 -fix logic (and BC break) 2010-08-23 18:05:05 +00:00
Pierre Joye b9d73bb910 - WS 2010-08-23 17:16:17 +00:00
Pierre Joye a6c5363f05 - revert fix for #52655, rev. 302614 2010-08-23 17:01:44 +00:00
Pierre Joye 6326528127 - add follow_location support for http stream, enabled by default to keep BC. Allows one to ignore the location header, w/o having to ignore errors or other tricks, the location data is however still available (meta) 2010-08-23 16:54:57 +00:00
Pierre Joye 1d7ce1aae0 - fix string validation entry, mops-2010-24 2010-08-23 14:25:48 +00:00
Kalle Sommer Nielsen 3947bfeadf Fixed bug #52655 (SimpleXMLIterator supports ArrayAccess without implementing the interface) 2010-08-21 16:22:46 +00:00
Felipe Pena da3743b7b9 - Added missing void parameter checks 2010-08-21 16:09:18 +00:00
Jérôme Loyet 6db49b7864 - Fix #52407 (use __sync_bool_compare_and_swap in fpm_atomic.h if gcc >= 4.1 is used - credit to geissert) 2010-08-21 06:46:18 +00:00
Jérôme Loyet 1f3aaf508c - typo (thx to sixd) 2010-08-20 17:00:57 +00:00
Pierre Joye 0f58370215 - fix string validation, MOPS-2010-24 2010-08-20 16:37:33 +00:00
Andrey Hristov 4348f9e163 svn up messed this 2010-08-20 15:39:03 +00:00
Andrey Hristov bb89f5c275 here comes the news 2010-08-20 12:29:59 +00:00
Andrey Hristov 27567040d2 Fix for bug #52654 mysqli doesn't install headers with structures it uses 2010-08-20 12:25:17 +00:00
Jérôme Loyet 72064e1a28 Fix #52609 (INI scanner did not use ZEND_INI_SCANNER_NORMAL) 2010-08-20 08:33:57 +00:00
Ilia Alshanetsky 06c460c995 Fixed bug #52599 (iconv output handler outputs incorrect content type when flags are used). 2010-08-19 12:27:13 +00:00
Kalle Sommer Nielsen 0b1477a716 Use userland function name, not internal name for NEWS 2010-08-18 20:26:42 +00:00
Kalle Sommer Nielsen e92ebce7f8 Fixed possible crash in php_mssql_get_column_content_without_type()
# Also fix NEWS entry in PHP_5_2 for previous commit
2010-08-18 20:16:05 +00:00
Kalle Sommer Nielsen c2c3467ab4 Fixed bug #52636 (php_mysql_fetch_hash writes long value into int)
# Tested by rein at basefarm dot no
2010-08-18 20:00:18 +00:00
Felipe Pena 2fb2f81538 - Improved fix for bug #52573 2010-08-18 01:59:37 +00:00
Andrey Hristov ed806c4461 here comes the news 2010-08-17 18:10:08 +00:00
Andrey Hristov 2a926ec6ec Fix for Bug #52613 crash in mysqlnd 2010-08-17 18:08:25 +00:00
Andrey Hristov 33c7b63c6c Update with PHP_DEF_FE, also update the test 2010-08-17 18:07:11 +00:00
Kalle Sommer Nielsen a109c3538f Fix my fix for arginfo, trunk patch will follow shortly 2010-08-17 13:34:11 +00:00
Kalle Sommer Nielsen 5a3624221b Fixed the $context parameter on copy() to have an effect (approved for 5.3 by Johannes)
# To not change a PHPAPI in a point release, a new function have been added to support contexts:
# php_copy_file_ctx(), php_copy_file_ex() now simply wraps to that
2010-08-17 12:17:28 +00:00
Kalle Sommer Nielsen a780e73f62 Fix arginfo for copy(), see r302376 for more info 2010-08-16 21:59:42 +00:00
Kalle Sommer Nielsen cee97080d1 Fixed bug #50836 (run_tests.php alerts syntax errors while testing session) 2010-08-16 20:56:00 +00:00
Andrey Hristov c204922c7f Added utf16 and utf32 support, as in MySQL 5.5, in mysqlnd.
Fixed tests, so they don't try to use SET NAMES utf16|utf32,
as character_set_client can't be set to those (the lexer can't
read ucs2, utf16 and utf32).
Added support for 4-byte utf8, as found in MySQL 5.5
2010-08-16 17:44:50 +00:00
Andrey Hristov 0a9ca62a77 Fix test, so it doesn't fail with MySQL 5.5, where InnoDB
is the default engine
2010-08-16 16:15:15 +00:00
Andrey Hristov 4d72dba301 detect easily which charset doesn't work 2010-08-16 16:13:55 +00:00
Derick Rethans e577899507 - Updated to version 2010.12 (2010l) 2010-08-16 12:48:53 +00:00
Pierre Joye 894dc2480c - WS 2010-08-16 10:29:01 +00:00
Andrey Hristov f8e312ea27 Here comes the news 2010-08-16 09:45:26 +00:00
Andrey Hristov 2f2cdc6a51 Sync with trunk, fixes build failure on MacOSX.
Fix for Bug #52417 MySQLi build failure with mysqlnd
2010-08-16 09:44:13 +00:00
Derick Rethans 6c579efc43 - Updated to version 2010.11 (2010k) 2010-08-16 09:32:51 +00:00
Dmitry Stogov 7ca414f5e7 Bug #52361 (Throwing an exception in a destructor causes invalid catching) 2010-08-16 09:20:46 +00:00
Dmitry Stogov 890c709036 Fixed memory leaks (related to bug #52361) 2010-08-16 08:11:08 +00:00
Kalle Sommer Nielsen 61a1bad720 Fixed bug #52593 (exif is placed before mbstring in php.ini) 2010-08-16 00:26:39 +00:00
Pierre Joye 4588d5d79f - #52607, fix ENV conflit with win SDK 7.1 2010-08-15 13:54:03 +00:00
Pierre Joye bb669f2c1b - year++ 2010-08-15 13:40:29 +00:00
Pierre Joye 1bd381890d - #52607, fix ENV conflit with win SDK 7.1 2010-08-15 03:38:08 +00:00
Ilia Alshanetsky bbeafa1dcf Win32 build fixes 2010-08-14 14:47:49 +00:00
Ilia Alshanetsky 842bc947e2 Upgraded bundled Sqlite3 to version 3.7.0.1 2010-08-14 14:44:39 +00:00
Ilia Alshanetsky c5602787fc MFH: Upgraded bundled PCRE to version 8.10. 2010-08-14 14:37:13 +00:00
Felipe Pena c101964325 - Fixed the fix for bug #52546 2010-08-13 22:12:37 +00:00
Kalle Sommer Nielsen e72a69aae6 Changed mysqli_report() to be per-request specific rather than per-process specific (Fixes #52390) 2010-08-13 10:43:15 +00:00
Andrey Hristov a6100682d0 Fix for bug #52413 MySQLi build failure on OS X 2010-08-13 09:57:04 +00:00
Andrey Hristov 973e134d2d Fix for bug #52433 Call to undefined method mysqli::poll() 2010-08-13 09:18:06 +00:00
Sascha Schumann 14edb68858 - fix cast 2010-08-12 17:28:08 +00:00
Andrey Hristov 8409cb44b2 Make this function static, as it is used only in this file.
Add additional comment about how it works.
2010-08-12 14:17:31 +00:00
Andrey Hristov 6fc06f265e Allocate memory in a burst mode, and later use it. Increases
locality of the data.
Also use MYSQLND_INC_CONN_STATISTIC in one place, instead of
two, thus removing code duplication from macro expansion - less
code to fit in the instruction cache.
2010-08-12 13:23:16 +00:00
Andrey Hristov 92ef63a07b Switch from using PHP_MAJOR_VERSION to separate define for
unicode. Unicode is no more, but these are "bookmarks" where
to change mysqlnd, if Unicode becomes trendy again.
2010-08-12 12:02:02 +00:00
Andrey Hristov 8bf7114691 ws + cs 2010-08-12 11:38:08 +00:00
Sascha Schumann 50a0ea7b8c separate properties of internal classes in ZTS mode fully,
otherwise multiple threads will modify the zvals' contents
without any synchronisation.
2010-08-12 07:58:14 +00:00
Kalle Sommer Nielsen 49f22527cc Fixed bug #50804 (Document configure.js --enable-crt-debug) 2010-08-11 22:38:15 +00:00
Kalle Sommer Nielsen 1e4d963734 Ignore the x64 directory for Windows x64 builds 2010-08-11 21:26:09 +00:00
Kalle Sommer Nielsen 1178d719ea Seems like this one skipped the commit (E_ERROR -> E_CORE_ERROR) for zend.ze1_compatibility_mode (re #52570) 2010-08-11 21:18:45 +00:00
Kalle Sommer Nielsen 8deefa8780 Changed deprecated ini options on startup from E_WARNING to E_DEPRECATED (Fixes #52570)
# Trunk patch will follow shortly
2010-08-11 21:12:18 +00:00
Dmitry Stogov 7d55780ca0 In ZTS mode default properties and constants of internal classes can't be modified in place and have to be separated 2010-08-11 09:38:41 +00:00
Felipe Pena 658272c9ee - Fixed bug #52573 (SplFileObject::fscanf Segmentation fault) 2010-08-10 22:37:24 +00:00
Andrey Hristov 0d3d292633 Fix Request #52302 mysqli_fetch_all does not work with MYSQLI_USE_RESULT 2010-08-09 17:29:30 +00:00
Andrey Hristov f8c2680509 Lay foundations for named pipe support in mysqlnd 2010-08-09 17:01:57 +00:00
Pierre Joye cf7d0fb4e7 - #52523, fix logic (0 is perfectly valid as part of the data, bin data) 2010-08-09 08:14:14 +00:00
Pierre Joye 1e26362d4b - WS 2010-08-09 07:32:21 +00:00
Felipe Pena 904b9282fe - Fixed bug #50481 (Storing many SPLFixedArray in an array crashes) 2010-08-08 23:56:29 +00:00
Ilia Alshanetsky 7ab1a74f49 Additional fix for bug #52550 & fix test & warning from previous fixes 2010-08-08 15:45:02 +00:00
Christopher Jones d0dc4810eb Fixed bug #51610 (Using oci_connect causes PHP to take a long time to exit). Do PECL OCI8 1.4.3 release 2010-08-07 00:24:26 +00:00
Felipe Pena afed1468e4 - Added missing SKIPIF 2010-08-06 23:05:39 +00:00
Felipe Pena f4644c8c85 - Fix test 2010-08-06 23:01:32 +00:00
Felipe Pena 07c1929a7a - Fixed bug #52533 (ext/curl/tests/curl_multi_getcontent_basic3.phpt broken due php.net/robots.txt)
patch by: glen at delfi dot ee
2010-08-06 22:57:41 +00:00
Felipe Pena 8be696d143 - Updated generated file 2010-08-06 22:23:10 +00:00
Felipe Pena 7e8ec822a5 - Fix build 2010-08-06 22:21:13 +00:00
Johannes Schlüter 97317c7b1e - ext_skelshould create a .svnignore not .cvsignore these days 2010-08-06 22:19:47 +00:00
Christopher Jones a59ffde6bc Release PECL OCI8 1.4.2 2010-08-06 22:12:48 +00:00
Ilia Alshanetsky fbe6499d46 WS 2010-08-06 20:16:11 +00:00
Ilia Alshanetsky 231d8dd526 Another fix for issue indentified in bug #52550 2010-08-06 20:04:29 +00:00
Ilia Alshanetsky c0edb4afce Fixed issues inside str_pad() identified by bug #52550 2010-08-06 19:55:10 +00:00
David Soria Parra 9d02d50df2 make ssl_set return value in mysqlnd compatible with libmysqli return value 2010-08-06 19:47:03 +00:00
Ilia Alshanetsky 64ceec13f2 Use correct order of operations. Second of many fixes for bug #52550 2010-08-06 19:11:34 +00:00
Rasmus Lerdorf 0d1ab2f6ac Fix 5.3 as well 2010-08-06 18:20:41 +00:00
Felipe Pena f171aefb31 - Fixed bug #52546 (pdo_dblib segmentation fault when iterating MONEY values) 2010-08-05 23:32:18 +00:00
Felipe Pena 1e17bb2aab - Fixed bug #52534 (var_export array with negative key) 2010-08-04 23:11:44 +00:00
Jérôme Loyet 5fe988518a BUG: all value comparaisons were not case insensitive in the conf file parser 2010-08-02 21:46:52 +00:00
Jérôme Loyet c80e055c9c typo 2010-08-02 09:28:54 +00:00
Jérôme Loyet 1c50d5385d correct php-fpm.conf: slowlog has no default value 2010-08-02 09:02:48 +00:00
Felipe Pena 6150174941 - Fixed bug #52468 (wddx_deserialize corrupts integer field value when left empty) 2010-08-01 17:34:09 +00:00
Felipe Pena 3ef14fc609 - Fixed bug #52508 (newline problem with parse_ini_file+INI_SCANNER_RAW) 2010-08-01 15:26:54 +00:00
Felipe Pena c0e6f37cb9 - Fixed bug #52484 (__set() ignores setting properties with empty names) 2010-08-01 13:27:02 +00:00
Felipe Pena cb1d315b7d - Fix tests 2010-07-31 22:10:43 +00:00
Felipe Pena 30a8dcff1b - New test 2010-07-29 23:46:49 +00:00
Felipe Pena e3ddef53b4 - Fixed bug #52487 (PDO::FETCH_INTO leaks memory) 2010-07-29 23:38:55 +00:00
Jérôme Loyet 4445c85d4f - Fixed bug #52476 (move php-fpm man page from section 1 to section 8) 2010-07-29 22:07:00 +00:00
Raphael Geissert 444bba79ba Fix required facilities for php-fpm's init script
$all should only be used in rare, and very specific, cases.
2010-07-29 19:13:42 +00:00
Pierre Joye 110fab9803 - fix build 2010-07-29 11:58:41 +00:00
Sriram Natarajan a0bf0739a9 - Fixed bug #52436 (Compile error in pcre if systems do not have stdint.h)
# PCRE's config.h can very well reuse the definitions made available from
# PHP's configure script output available within php_config.h
2010-07-27 21:42:22 +00:00
Pierre Joye ed4f6dbd36 - make libsasl optional (as vc6 bins do not have it) 2010-07-26 22:28:38 +00:00
Rasmus Lerdorf 94286b35e3 Let's keep NEWS entries to things that might affect users.
A typo in a comment isn't very news-worthy.
2010-07-23 15:52:34 +00:00
Adam Harvey 3aceb07efd MFH: fix bug #52380 (Typo in lcfirst comment docs). 2010-07-23 09:02:14 +00:00
Adam Harvey ebc6982eb8 Correct bug ID in the NEWS file for posterity. 2010-07-23 08:58:03 +00:00
Johannes Schlüter 200b139c69 - Back to -dev 2010-07-22 11:08:31 +00:00
Johannes Schlüter 6212b88ef3 - PHP 5.3.3 2010-07-21 10:50:07 +00:00
Johannes Schlüter 72ff4aac7e - merge NEWS for 5.2.14 and 5.3.3 2010-07-21 09:02:45 +00:00
Pierre Joye 426e14a6ed - add CVE # 2010-07-20 09:26:29 +00:00
Adam Harvey 5ce0bb46f6 MFH: fix for bug #52317 (Segmentation fault when using mail() on a rhel 4.x
(only 64 bit)).
2010-07-19 13:38:53 +00:00
Adam Harvey 2e1cd1e133 Revert r301354, since we don't need a test for a bogus bug. 2010-07-19 09:58:19 +00:00
Kai Schroeder 5126ac9ab0 Test for #50475 2010-07-17 23:29:52 +00:00
Kai Schroeder c11850b406 Test for #51819 2010-07-17 23:20:24 +00:00
Kai Schroeder b1fb44660d Test for #48187 2010-07-17 22:47:13 +00:00
Kai Schroeder 221c71032f Test for #51994 2010-07-17 22:17:48 +00:00
Kai Schroeder d53e8cfb83 Test for #52290 2010-07-17 21:57:16 +00:00
Kai Schroeder ede218d54c Test for #52359 2010-07-17 21:26:01 +00:00
Andrey Hristov a30113b617 Fix for Bug #51583 Bus error due to wrong alignment in mysqlnd 2010-07-15 16:57:14 +00:00
Pierre Joye 1dc9e43cd0 - fix vc6 build 2010-07-15 00:13:20 +00:00
Johannes Schlüter 50554563af Back to -dev 2010-07-14 23:40:42 +00:00
Johannes Schlüter 6d85947b52 PHP 5.3.3RC3 2010-07-14 23:01:42 +00:00
Dmitry Stogov 4c961e9045 Fixed incorrect reinitialization 2010-07-14 10:27:08 +00:00
Kalle Sommer Nielsen d733338225 Update the re2c files aswell (bug #51943) 2010-07-14 00:04:43 +00:00
Kalle Sommer Nielsen e71ee33358 Fixed bug #51943 (Several files are out of ANSI spec)
# Based on patch by CoreyStup at gmail dot com
2010-07-13 23:59:54 +00:00
Kalle Sommer Nielsen 00fabe553a MFT: Fixed bug #52037 (Concurrent builds fail in install-programs) -- Patch by Seanius at debian dot org
# Sorry for the non sparse commit, due to a broken co
2010-07-13 17:24:13 +00:00
Andrey Hristov e6dc3a5cbc Give an error when USE_RESULT is used with fetch_all 2010-07-13 13:02:00 +00:00
Scott MacVicar c02f6724a8 Doing this as a seperate commit unless we need to back it out.
Fix a bug when var_export() causes a fatal error that could inadvertently display data due to flushing of the output buffer.

Examples include, memory limit, execution time and recursion.
2010-07-09 21:19:27 +00:00
Andrey Hristov f20dd1f9ae adding arginfo to mysqli fixed the bug 2010-07-08 10:18:46 +00:00
Felipe Pena 5f790678ec - Fixed ZTS build 2010-07-07 22:46:54 +00:00
Etienne Kneuss a3bf7aa4fe Fixed #51697 (Unsafe operations in free_storage of SPL iterators,
causes crashes during shutdown)
2010-07-07 21:55:17 +00:00
George Wang 6106c44c10 applied patch from bug report 51452 2010-07-07 20:03:04 +00:00
Andrey Hristov e670162315 Cleanup in trunk. Remove some functions, noted in
UPGRADING. sed-ed the tests to change the usage
to the real function name.
2010-07-07 12:09:36 +00:00
Andrey Hristov ce1bd65d29 arginfo for mysqli, was too fast to commit in trunk instead of one
directory up, thus the patch was split in two.
2010-07-07 11:37:35 +00:00
Timm Friebe a4ff8bce62 - MFT: Added -DSYB_LP64 to CFLAGS on 64 bit platforms
- MFT: Added checks for 64 bit versions of sybase libraries
- MFT: Added checks for sybase libraries prefixed with "libsyb"
2010-07-07 10:15:24 +00:00
Scott MacVicar e1ce0a64ea Fix bug #52262 - Invalid UTF-8 documents don't set an error code when they fail to decode. 2010-07-06 17:01:30 +00:00
Antony Dovgal 336b5af34b fix typos and use correct directive names in error messages 2010-07-06 11:37:19 +00:00
Felipe Pena a4d1188313 - Fixed tests 2010-07-06 00:25:52 +00:00
Dmitry Stogov 09d8bbb2ee Fixed bug #52237 (Crash when passing the reference of the property of a non-object) 2010-07-05 09:08:35 +00:00
Felipe Pena 0891e86ed8 - Fixed bug #52240 (hash_copy() does not copy the HMAC key, causes wrong results and PHP crashes) 2010-07-03 13:06:14 +00:00
Johannes Schlüter e46fee1d1a Fix bug #52238: Crash when an Exception occured in iterator_to_array 2010-07-02 19:17:45 +00:00
Johannes Schlüter c06a26a524 Back to -dev 2010-07-02 07:32:05 +00:00
Eric Stewart 3b38626603 Added test for bug 52013 to PHP_5_3. 2010-07-02 02:46:43 +00:00
Johannes Schlüter 2b48156eab 5.3.3 RC2 2010-07-01 15:44:18 +00:00
Felipe Pena 92ba590555 - BFN 2010-07-01 01:12:21 +00:00
Pierre Joye 1fe5265c3e - WS 2010-06-30 22:06:49 +00:00
Ilia Alshanetsky 112ac7e978 Fixed bug #33210 (getimagesize() fails to detect width/height on certain JPEGs). 2010-06-30 12:21:35 +00:00
Stanislav Malyshev af2d266a09 sync version with PECL 2010-06-30 04:23:32 +00:00
Felipe Pena 4e606e3ceb - Fixed bug #48930 (__COMPILER_HALT_OFFSET__ incorrect in PHP >= 5.3) 2010-06-30 02:45:10 +00:00
Felipe Pena 96bb25e8e7 - Reverted fix for bug #48930 (due binary compatibility breakage) 2010-06-29 11:37:13 +00:00
Stanislav Malyshev 865f85718f fix SplObjectStorage unserialization (CVE-2010-2225) 2010-06-29 00:58:31 +00:00
Pierre Joye 9c60bd8df7 - typo for iconv DLL .lib 2010-06-28 23:26:48 +00:00
Felipe Pena a8e80ec235 - Reverted fix for bug #51421 2010-06-28 16:37:57 +00:00
Felipe Pena 0488a86634 - Fix arginfo name 2010-06-28 01:19:08 +00:00
Felipe Pena ced29dd706 - Improved initialization 2010-06-27 22:13:41 +00:00
Felipe Pena 9b07568c43 - Fixed bug #48930 (__COMPILER_HALT_OFFSET__ incorrect in PHP >= 5.3) 2010-06-27 21:46:16 +00:00
Felipe Pena 0cc45e7bdb - BFN 2010-06-26 22:07:04 +00:00
Felipe Pena 10a9634bc9 - Fixed bug #51421 (Abstract __construct constructor argument list not enforced) 2010-06-26 22:05:13 +00:00
Felipe Pena eb5e97adf5 - Fixed bug #52160 (Invalid E_STRICT redefined constructor error) 2010-06-26 19:19:16 +00:00
Felipe Pena 419f589580 - Fixed tests 2010-06-26 17:17:47 +00:00
Felipe Pena 9ea7a70e24 - Fixed bug #52193 (converting closure to array yields empty array) 2010-06-26 17:14:33 +00:00
Felipe Pena e64734f986 - Fixed bug #52183 (Reflectionfunction reports invalid number of arguments for function aliases) 2010-06-26 16:03:39 +00:00
Christopher Jones 22458ed4d5 Remove hard coded lib extension. Prepare for OCI8 1.4.2 release 2010-06-25 21:18:09 +00:00
Christopher Jones 86544f5971 Fix bug #52186 (phpinfo shows 10.1 or 11.1 when installed with ORACLE_HOME 10.2 or 11.2) 2010-06-25 21:09:13 +00:00
Felipe Pena 5a3a34e3e6 - Fixed bug #52138 (Constants are parsed into the ini file for section names) 2010-06-24 22:32:42 +00:00
Andrey Hristov 89bd3af6b9 Two functions, which should be methods so one can catch
their output, for example
2010-06-24 19:52:13 +00:00
Pierre Joye d27d572a7d - typo 2010-06-24 00:15:12 +00:00
Sriram Natarajan 2bb9bbb803 - Fixed bug #52162 (custom request header variables with numbers are removed) 2010-06-23 19:06:33 +00:00
Johannes Schlüter 08e1471c16 Install SQLite3 header 2010-06-23 15:11:02 +00:00
Andrey Hristov 53324e8830 Fix sprintf modifiers all around the place. In most cases
%u should be used. Where size_t is used then MYSQLND_SZ_T_SPEC should be
the modifier
2010-06-21 15:32:26 +00:00
Andrey Hristov 698539fa79 fix valgrind warnings on 64bit, thread_is is strictly 32bit 2010-06-21 14:49:45 +00:00
Ilia Alshanetsky 6b990988f1 MFB: Implemented FR #51295 (SQLite3::busyTimeout not existing). (Mark) 2010-06-21 11:06:31 +00:00
Pierre Joye 6ee4060bfa - #45808, stream_socket_enable_crypto() blocks and eats CPU 2010-06-20 16:33:16 +00:00
Felipe Pena c6e852d7db - Completed the fix for bug #52010
# Fixing pdo drivers
2010-06-20 14:12:06 +00:00
Jérôme Loyet ffdd175918 - Fixed bug #52086 (No new line at the end of a included file crahes the PHP FPM daemon) 2010-06-19 16:31:19 +00:00
Andrey Hristov 5a4a66cdd5 Fix for bug #52115 mysqli_result::fetch_all returns null, not an empty array 2010-06-18 17:25:41 +00:00
Andrey Hristov 6b730a04ae missed this one in the last commit, the real type 2010-06-18 12:00:57 +00:00
Andrey Hristov 7f79e86886 fix type mismatch, this is fresh misunderstanding 2010-06-18 11:56:25 +00:00
Johannes Schlüter 7d0eedf08c - Ignore empty filename for mail.log, treat it like none given 2010-06-18 10:16:35 +00:00
Ulf Wendel f3448471df Don't bail if there is another extension that exports constants starting with mysql<something> 2010-06-18 09:56:18 +00:00
Johannes Schlüter d52e132203 back to -dev 2010-06-18 08:22:14 +00:00
Johannes Schlüter 8661e8d298 PHP 5.3.3RC1 2010-06-17 17:16:57 +00:00
Johannes Schlüter 8a142cb861 5.3.3RC1 2010-06-17 17:10:16 +00:00
Pierre Joye a46cb6b513 - fix build 2010-06-17 16:56:48 +00:00
Johannes Schlüter 06c987663a - 80 lines are nice, sentences stop with a period
- Merge in 5.3.2 NEWS ...
2010-06-17 12:31:57 +00:00
Andrey Hristov ae4ae5a313 split mysqlnd_connect() in two parts, one doing the authorization 2010-06-17 11:37:49 +00:00
Pierre Joye c4c6b69b64 - #51424 2010-06-17 10:22:51 +00:00
Pierre Joye 84f3b13264 - #51424, solaris part 2010-06-17 10:22:03 +00:00
Pierre Joye 49418ce7da - Fix bug #52101, dns_get_record()garbage in 'ipv6' field 2010-06-17 09:26:29 +00:00
Felipe Pena d4746a659e - BFN 2010-06-16 23:40:23 +00:00
Felipe Pena 42c4bafbbd - New tests related to #52098 2010-06-16 23:33:01 +00:00
Felipe Pena d596ea742a - Fix crash when calling a method of a class that inherits PDOStatement if instantiated directly 2010-06-16 23:13:29 +00:00
Andrey Hristov d47e50a9ff no more needed because of the charset fix in the previous changeset 2010-06-16 19:01:13 +00:00
Pierre Joye cfd930d218 - #50563, removing E_WARNING from parse_url() 2010-06-16 18:56:24 +00:00
Pierre Joye 4029454a0d - Fix bug #50578, incorrect shebang in phar.phar 2010-06-16 18:30:35 +00:00
Timm Friebe ec54570362 - MFT: Fixed segmentation fault when reading rows
# Problem surfaces when using FreeTDS, ASE 12.5 and reading text fields
# with NULL values. This is essentially a workaround for a bug in Free-
# TDS which is not setting the NULL indicators correctly, but provides
# a protection against possible segfaults if any other driver ever does
# this again:-)
2010-06-16 09:49:25 +00:00
Antony Dovgal 3896e7403d improve ptrace() test
change error to warning - there can be no trace method available at all
2010-06-16 08:58:42 +00:00
Ben Longden ddc9246071 Merged SplFileObject::fgetcsv tests from trunk 2010-06-15 21:42:04 +00:00
Felipe Pena f310305fc2 - New entries 2010-06-15 19:37:20 +00:00
Pierre Joye 2cfb5e4254 - Fix #51002, fix possible memory corruption with very long names 2010-06-15 18:48:33 +00:00
Pierre Joye 33ac0d0e33 - cleanup, no vc6 support in trunk 2010-06-15 13:50:14 +00:00
Pierre Joye d686b7579a - #51424, silent warnings on win 2010-06-15 13:43:15 +00:00
Ben Longden d1c912628d Merged SplTempFileObject tests from trunk 2010-06-15 11:20:21 +00:00
Ilia Alshanetsky 24b8bc3489 Removed the in_transaction handler for 5.3 to avoid BC break due to structure change 2010-06-15 11:13:20 +00:00
Pierre Joye 8fcd33ed18 - Fix #51424, crypt() function hangs after 3rd call 2010-06-15 09:26:06 +00:00
Dmitry Stogov 3d5f729181 Fixed bug #52041 (Memory leak when writing on uninitialized variable returned from function) 2010-06-15 08:22:51 +00:00
Andrey Hristov 0da5464a81 Fix the test for libmysql, which expects the certificates
to be in the directory where the interpreter is started. When
using mysqlnd they should not include path and will be found
in the directory of the script.
2010-06-14 18:23:17 +00:00
Andrey Hristov 83051b1a86 And a fix for MySQL Server which is pre 5.1.23, which doesn't support
preserving of the charset when performing change_user. This is libmysql
only code.
2010-06-14 18:19:13 +00:00
Andrey Hristov 1d9c49bb3c Fixed bug #52082 (character_set_client & character_set_connection reset after
mysqli_change_user())

libmysql >= 5.1.23 will PASS, older library versions will fail
2010-06-14 17:16:20 +00:00
Pierre Joye 0296501274 - MFH 2010-06-14 09:56:50 +00:00
Pierre Joye 22df3125d5 - drop comment 2010-06-14 09:15:20 +00:00
Pierre Joye d652e02235 - #52043,GD doesn't recognize latest libJPEG version 2010-06-14 08:12:10 +00:00
Jérôme Loyet 205775507a Fix #52067, chroot and chdir path were not checked at startup. If configured with unexistant directories, FPM entered in an error loop. 2010-06-13 10:30:35 +00:00
Felipe Pena 764a95f6f3 - Fixed bug #49320 (PDO returns null when SQLite connection fails) 2010-06-12 22:04:48 +00:00
Felipe Pena f1e02c5cc7 - Fixed bug #52051 (handling of case sensitivity of old-style constructors changed in 5.3+) 2010-06-12 15:30:21 +00:00
Felipe Pena 4d3944f941 - Fixed bug #52057 (ReflectionClass fails on Closure class) 2010-06-11 23:37:55 +00:00
Felipe Pena 5eb64a4957 - Fixed bug #52060 (Memory leak when passing a closure to method_exists()) 2010-06-11 23:20:13 +00:00
Patrick Allaert 899bc2f582 - Fixed bug #52019 (make lcov doesn't support TESTS variable anymore) 2010-06-11 14:04:57 +00:00
Dmitry Stogov d24c14cb59 Fixed bug #51552 (debug_backtrace() causes segmentation fault and/or memory issues) 2010-06-11 08:53:31 +00:00
Ulf Wendel afcb62ba1e Fixing tests 2010-06-10 13:40:13 +00:00
Andrey Hristov 7aaef918a6 export mysqlnd_globals_id, per Johannes 2010-06-10 12:24:03 +00:00
Ilia Alshanetsky 90906a91e9 Added inTransaction() method to PDO, with specialized support for Postgres 2010-06-10 12:11:19 +00:00
Dmitry Stogov 748dd20476 Fixed bug #51822i (Segfault with strange __destruct() for static class variables) 2010-06-10 11:45:51 +00:00
Ilia Alshanetsky 9daa864c4f Added support for copy to/from array/file for pdo_pgsql extension.
# original patch by Denis Gasparin
2010-06-10 11:11:29 +00:00
Andrey Hristov e692080fc5 void functions return nothing 2010-06-10 09:37:58 +00:00
Dmitry Stogov cac310d87e Fixed bug #52001 (Memory allocation problems after using variable variables) 2010-06-10 09:13:22 +00:00
Christopher Jones 442fa8dc1b Explicitly use db-5.0 and don't default to db sym link 2010-06-09 17:33:44 +00:00
Ilia Alshanetsky f7d82d0e0d Fixed bug #52010 (open_basedir restrictions mismatch on vacuum command). 2010-06-09 16:04:54 +00:00
Ilia Alshanetsky 0d4720a61b Fixed bug #51273 (Faultstring property does not exist when the faultstring is empty)
# Patch by dennis at transip dot nl
2010-06-09 15:48:22 +00:00
Pierre Joye 9e5313fdca - [DOC] MFH: add session.entropy* support to windows 2010-06-08 22:30:16 +00:00
Pierre Joye 32447e4902 - restore previous setting 2010-06-08 22:27:14 +00:00
Sriram Natarajan dbddbb6e34 - Fixed Bug #51168 (fails to compile with Sun Studio)
# C99 standard supports inline keyword and supported by
 # by major compilers like GCC, HP C, IBM C and Sun C
2010-06-08 21:23:48 +00:00
Felipe Pena 178ee9325d - Fix order 2010-06-08 19:47:04 +00:00
Antony Dovgal 3c9e1e6d70 support both 'warn' and 'warning' as error levels 2010-06-08 18:59:11 +00:00
Pierre Joye 73a413bdea - use new function to get random bytes 2010-06-08 18:27:23 +00:00
Pierre Joye 481f77890d - WS 2010-06-08 18:26:03 +00:00
Ulf Wendel 20f6aaeca9 Make the tests pass with sql strict mode enabled 2010-06-08 15:47:51 +00:00
Ulf Wendel aeae0d1bad Portability improvement 2010-06-08 14:57:10 +00:00
Ulf Wendel 3e5ac35bd9 Portability improvements 2010-06-08 14:29:05 +00:00
Pierre Joye 761dbeedbb - duplicate entry 2010-06-08 13:48:02 +00:00
Pierre Joye f8b17007e0 - [DOC] add session.entropy* support to windows 2010-06-08 13:46:19 +00:00
Antony Dovgal 9badd4f0fb fix bug #50101 (name clash between global and local variable) 2010-06-08 13:27:30 +00:00
Ulf Wendel 6b1d256af5 More SQL strict mode updates 2010-06-08 13:05:49 +00:00
Pierre Joye 68cd943189 - add striped down version of RNG layer to have a reliable random src on windows 2010-06-08 13:00:54 +00:00
Pierre Joye 5afc8e2c83 - add striped down version of RNG layer to have a reliable random src on windows 2010-06-08 13:00:11 +00:00
Antony Dovgal ae01c146d1 fix bug #51276 (php_load_extension() is missing when HAVE_LIBDL is undefined) 2010-06-08 12:54:11 +00:00
Antony Dovgal a8be1c1d4b fix micro-memleaks (happened once per process) 2010-06-08 12:02:55 +00:00
Ulf Wendel 0fb528edee Making tests pass strict sql mode. 2010-06-08 10:55:12 +00:00
Felipe Pena b65a473efb - Let's generate this #ifdef only on zend_vm_execute.h 2010-06-07 23:04:30 +00:00
Felipe Pena d78fb2b14a - Fix script 2010-06-07 14:37:35 +00:00
Pierre Joye 6d1d27bc3a - show the free_op1 warning only once, until a fix is applied 2010-06-07 01:37:59 +00:00
Pierre Joye 707980c2be - show the free_op1 warning only once, until a fix is applied 2010-06-06 20:32:51 +00:00
Pierre Joye badf05a8ea - silent warning (unary minus operator applied to unsigned type) 2010-06-06 15:28:30 +00:00
Pierre Joye b690b940ca - label only used when mmap is available 2010-06-06 12:32:25 +00:00
Christopher Jones 5441c86936 New test for file_exists (bug #39863). It currently xfail's 2010-06-05 19:44:48 +00:00
Felipe Pena a14dd7502b - Fixed bug #51991 (spl_autoload and *nix support with namespace) 2010-06-04 00:10:15 +00:00
Felipe Pena c42d8b3776 - Fix proto and argname 2010-06-03 18:39:21 +00:00
Felipe Pena 7deae5022d - Added ZipArchive arginfo 2010-06-03 18:23:14 +00:00
Christopher Jones 9ef6a73dee Add Berkeley DB 5 support. (An outstanding issue with BDB 4.8 related to 51086 that also affects BDB 5 is not yet resolved) 2010-06-03 07:03:05 +00:00
Felipe Pena 8454cca44c - Fix memleak when passing a non string/object parameter 2010-06-03 00:43:37 +00:00
Rasmus Lerdorf a259f797bf vim fail 2010-06-02 19:26:10 +00:00
Rasmus Lerdorf 6ba6263817 Tweak the fix for bug #51847 to still call libintl_setlocale
when libintl has done that redefine.
2010-06-02 19:24:36 +00:00
Pierre Joye 24ef65019f - silent warning 2010-06-02 19:20:04 +00:00
Pierre Joye c453a8fcda - fix leak on error in mcrypt_create_iv on windows 2010-06-02 15:27:38 +00:00
Pierre Joye 7c1d43dd95 - allow shared build 2010-06-02 10:00:58 +00:00
Rasmus Lerdorf d4cca6da93 Fix for bug #51847
Someone in libintl world decided it was a good idea to do:

#undef setlocale
#define setlocale libintl_setlocale

That means, of course, that any use of "setlocale" by the
preprocessor now becomes libintl_setlocale which means we
no longer have a _zif_setlocale symbol in string.o, but we
magically have a _zif_libintl_setlocale symbol.  The linker
is obviously not very happy about this when basic_functions.o
tries to find _zif_setlocale.

So, let's not do that again.
2010-06-02 05:53:13 +00:00
Johannes Schlüter d7b1fa9d35 Berkeley DB 5's SQL frontend gives a slightly different error than libsqlite 2010-06-01 16:39:36 +00:00
Andrey Hristov 4a0b4494d4 defensive programming, check before using a resource 2010-06-01 14:16:27 +00:00
Andrey Hristov 41406516b6 Perform later initialization 2010-06-01 09:47:46 +00:00
Andrey Hristov 2a043ed2d3 More check for valid MYSQLND_STMT before using it 2010-05-31 18:26:19 +00:00
Andrey Hristov 38f6c131e5 Don't reference row_packet before checking if dereferencing is possible 2010-05-31 18:18:37 +00:00
Andrey Hristov b472636375 Check if data is correct and initialize in a safe manner 2010-05-31 18:10:25 +00:00
Andrey Hristov 047d6f2855 Handle problems in the row_decoder, return type used to be void,
now it can return on problems.
2010-05-31 17:57:03 +00:00
Andrey Hristov b61d7501c9 Bail if allocation fails 2010-05-31 17:09:13 +00:00
Andrey Hristov 4cd5db922b Fix test 2010-05-31 16:53:33 +00:00
Andrey Hristov cf140b3bf7 try to workaround problems with non-c99 on HPUX 2010-05-31 16:51:03 +00:00
Ulf Wendel c0a8ce2f61 Updating test to reflect the latest and more verbose mysqlnd error messages, updating mysqlnd error message as well. 2010-05-31 13:56:42 +00:00
Ulf Wendel 0ab82cecc2 Fixing test - see also gcov results 2010-05-31 13:28:15 +00:00
Ulf Wendel 9b334da667 Fixing test - make sure it checks the same conditions for libmysql and mysqlnd 2010-05-31 12:55:59 +00:00
Ulf Wendel fb80ebe102 Fixing test 2010-05-31 12:22:48 +00:00
Ulf Wendel 4b5666a539 Fixing mysqli_stmt_attr_set @ libmysql 2010-05-31 12:10:04 +00:00
Ulf Wendel 2613069cd4 Improve EXPECTF to work with other than default schemata 2010-05-31 10:52:14 +00:00
Pierre Joye 46c0f21386 - Added recent Windows versions to php_uname and fix undefined windows version 2010-05-30 07:46:45 +00:00
Pierre Joye e2d9e0ae70 - ws 2010-05-30 07:36:19 +00:00
Jérôme Loyet dbe35d87d6 fix commit 299383 2010-05-29 22:00:43 +00:00
Jérôme Loyet e750930899 typo (thx to Brian P. Mercer) 2010-05-29 10:39:35 +00:00
Dmitry Stogov 54caf22325 Fixed bug #50976 (Soap headers Authorization not allowed) 2010-05-28 12:18:03 +00:00
Dmitry Stogov 42d25dc2b2 Fixed bug #50762 (in WSDL mode Soap Header handler function only being called if defined in WSDL). (mephius at gmail dot com) 2010-05-28 10:52:16 +00:00
Johannes Schlüter 901fc6f3a4 These files talk about PHP 3, flex, CVS, ... interesting to archeologists only 2010-05-27 23:12:44 +00:00
Johannes Schlüter 9cfcc89a0b Update EXTENSIONS file 2010-05-27 23:08:39 +00:00
Johannes Schlüter 435405f5da Update credits 2010-05-27 22:51:28 +00:00
Johannes Schlüter bb3faf2d25 Make the credits script more verbose 2010-05-27 22:50:31 +00:00
Johannes Schlüter a622dd6bfb From user's perspective this was added 2010-05-27 22:41:36 +00:00
Jérôme Loyet 66ef4d185c bug: include paths were not evaluated to to full path 2010-05-27 22:31:28 +00:00
Jérôme Loyet ce03ced4d7 typo 2010-05-27 22:18:58 +00:00
Ulf Wendel ba6ee3fc06 Open server bug: mysqlnd works around it, libmysql fails. Let's skip because MySQL Server version tests are tricky and error prone. 2010-05-27 13:01:17 +00:00
Andrey Hristov 3aa95c59cc Check before use, because mysqlnd can return NULL
and this will crash. However, this can happen only in case of OOM.
2010-05-27 12:44:10 +00:00
Andrey Hristov 6ebe80be5d Don't use NULL pointer, always check before use 2010-05-27 12:39:12 +00:00
Ulf Wendel 6356bcbbb9 Test fixes and updates to work with a wider range of MySQL server configs 2010-05-27 12:09:39 +00:00
Andrey Hristov ce2fbe1931 Fix possible crashes, in case of OOM, due to half-baken
objects.
2010-05-27 12:05:02 +00:00
Andrey Hristov 5efee3d587 Fix crashes in the allocator in case of OOM. 2010-05-27 12:00:48 +00:00
Andrey Hristov b7385f02fd Fix deallocation which can crash if the object is half-baken.
Happens during OOM.
2010-05-27 08:51:46 +00:00
Antony Dovgal 4d005a8e65 merge FPM SAPI from trunk (as agreed with Johannes) 2010-05-26 15:14:43 +00:00
Andrey Hristov ce136a825c Don't use conn->net without checking if it is NULL, because
it can be NULL in OOM conditions. This would cause a crash.
2010-05-26 13:47:43 +00:00
Andrey Hristov 0d468290be Fix test 2010-05-26 13:36:49 +00:00
Andrey Hristov d6458c3b1e Add checks to check the underlying pointer in the resource.
It can happen that the underlying pointer is freed (like in
the case of connection reconnect), and then it cannot be allocated
anymore, which means that NULL will be used consequently by the
functions that fetch the resource and the crash is immediate.
2010-05-26 07:28:43 +00:00
Felipe Pena 00191c3c34 - Fixed bug #51899 (Parse error in parse_ini_file() function when empy value followed by no newline) 2010-05-26 02:18:17 +00:00
Felipe Pena c4be9c3890 - Fixed bug #51905 (ReflectionParameter fails if default value is an array with an access to self::) 2010-05-26 00:00:58 +00:00
Andrey Hristov 58f13c3c9f Handle the situation when MYSQLND_PROTOCOL's methods return NULL.
mysqlnd should not crash but gracefully return with an error.
2010-05-25 23:18:13 +00:00
Andrey Hristov bccf2cea5d Handle the situation when mysql_init()/mysqlnd_init()
return NULL. It is a rare case of OOM but PHP shouldn't crash, if possible.
2010-05-25 22:55:10 +00:00
Felipe Pena f3009cb596 - Fixed bug #51911 (ReflectionParameter::getDefaultValue() memory leaks with constant array) 2010-05-25 22:46:17 +00:00
Andrey Hristov c5ff0eb5b8 Gracefully handle OOM in mysqlnd_stmt_init. Release the handle
and return NULL.
2010-05-25 22:42:25 +00:00
Andrey Hristov bcdc3b30f7 Init should return status value because initialization can fail.
In this case mysqlnd_init() should return NULL to the end-user.
2010-05-25 22:40:47 +00:00
Andrey Hristov 621cdd9019 Use the specialized macro for this case 2010-05-25 22:38:11 +00:00
Andrey Hristov c389adb96a Use only memory that has been allocated 2010-05-25 22:36:33 +00:00
Andrey Hristov 4abc7a1e69 Access memory which was really allocated 2010-05-25 22:34:47 +00:00
Andrey Hristov 348880ce66 Fix shared build 2010-05-25 21:54:21 +00:00
Andrey Hristov 337513ffa0 Handle OOM in the code that generates PS Execute requests
to the server. Fixes crashes in case of OOM.
2010-05-25 19:19:29 +00:00
Andrey Hristov ed4ce335d8 Fix metadata duplicatin which wasn't crash-safe in case of OOM. 2010-05-25 18:14:37 +00:00
Rasmus Lerdorf 5583cd237f Check for -1 as well here 2010-05-24 23:52:11 +00:00
Rasmus Lerdorf 159369c68c Let's have a sane error message here instead of some cryptic zlib error 2010-05-24 23:27:39 +00:00
Andrey Hristov 29c99daa0f Check set->data for validity before using it.
Prevents crashes after OOM.
2010-05-21 13:37:18 +00:00
Andrey Hristov ef1eeff882 When OOM hits the wire, don't crash. 2010-05-21 13:06:52 +00:00
Andrey Hristov 9c90bf42c1 Fix for Bug #51870
PDO::fetchAll after a PDO::execute with bindings lead to a segv.

It is only in unreleased code and thus doesn't deserve a NEWS entry
2010-05-21 11:09:28 +00:00
Ilia Alshanetsky ea3a6539dc Added support for JSON_NUMERIC_CHECK option in json_encode() that converts
numeric strings to integers.
2010-05-20 19:37:52 +00:00
Christopher Jones 3bdc7518a2 New current()/next() test 2010-05-20 17:55:58 +00:00
Felipe Pena b4500e9b85 - Added arginfo 2010-05-20 17:28:16 +00:00
Antony Dovgal 797bb31e24 fix ZTS build 2010-05-20 11:20:44 +00:00
Sara Golemon 2655e63e10 MFH: Add IV to openssl_(en|de)crypt()
Add openssl_cipher_iv_length()
2010-05-19 21:18:16 +00:00
Michael Wallner 60c236be92 * fixed bug #47842 sscanf() does not support 64-bit values 2010-05-19 11:28:08 +00:00
Pierre Joye 0d47dff287 - #51854, fix logic (patch by Tjerk) 2010-05-18 19:39:39 +00:00
Andrey Hristov c91c86b743 Remove duplicated code.
Use one centralized functions for data extraction.
2010-05-18 11:50:31 +00:00
Michael Wallner 8a402bf368 fix typo 2010-05-18 08:02:10 +00:00
Michael Wallner f4994234e2 add missing news about backlog socket context option for stream_socket_server() 2010-05-18 07:49:15 +00:00
Michael Wallner a1de9f382a * fixed bug #49819: STDOUT losing data with posix_isatty() 2010-05-18 07:25:29 +00:00
Pierre Joye 50a1b1d06c - #43233 2010-05-17 20:22:20 +00:00
Pierre Joye 57cfa703bf - #43233, sasl support for ldap on windows 2010-05-17 20:09:42 +00:00
Pierre Joye df59ed1c11 - 51844 2010-05-17 18:56:43 +00:00
Pierre Joye a22cd02f2f - #51844, checkdnsrr does not support types other than MX 2010-05-17 18:55:35 +00:00
Dmitry Stogov 059e2be153 Fixed a possible crash because of recursive GC invocation 2010-05-17 07:50:33 +00:00
Rasmus Lerdorf 9db78b574b typo 2010-05-15 15:37:18 +00:00
Felipe Pena c9fc939be0 - Fixed bug #51827 (Bad warning when register_shutdown_function called with wrong num of parameters) 2010-05-14 23:48:03 +00:00
Andrey Hristov e3be1e0bea result_meta local storage 2010-05-14 16:42:17 +00:00
Andrey Hristov c881ee30ea Allow overloading of mysqlnd_result_meta_init().
Add free space for future hooks.
2010-05-14 15:11:56 +00:00
Andrey Hristov 34ffc8a6c4 Export MYSQLND_PROTOCOL methods 2010-05-14 13:32:27 +00:00
Andrey Hristov b86ebe46cb - Give possibility to overload mysqlnd_result_init().
- Always use conn->m->stmt_init instead of mysqlnd_stmt_init()
2010-05-14 13:18:39 +00:00
Andrey Hristov ce0ea97850 OOM fixes 2010-05-14 13:04:33 +00:00
Andrey Hristov a78fa3fcaf - initialize some variables
- initialize the methods in a shorter way, use the compiler.
 = on structures copies them. Allows also exportability of
 the methods.
2010-05-13 15:29:08 +00:00
Andrey Hristov 90f16527af Export the methods of MYSQLND_NET 2010-05-13 14:15:23 +00:00
Andrey Hristov aad53cbdec Export the result_metadata methods to external modules. 2010-05-13 11:16:11 +00:00
Andrey Hristov 87bac04bf1 Better fix for #51605 2010-05-13 11:05:09 +00:00
Dmitry Stogov 32a09f39be Fixed a possible resource destruction issues in shm_put_var() 2010-05-13 08:34:06 +00:00
Dmitry Stogov 24704df3a8 Fixed a possible memory corruption in ArrayObject::uasort() Reported by Stefan Esser 2010-05-13 08:09:54 +00:00
Felipe Pena a8cad398fc - Fixed bug #51791 (constant() aborts execution when fail to check undefined constant) 2010-05-13 02:13:30 +00:00
Christopher Jones c5a068e025 Errors using reserved words as methods 2010-05-12 21:34:32 +00:00
Dmitry Stogov 24a1dbabc8 Fixed a possible memory corruption in parse_str(). Reported by Stefan Esser 2010-05-12 11:32:25 +00:00
Dmitry Stogov f94a437d9d Fixed a possible information leak because of interruption of XOR operator 2010-05-12 11:10:06 +00:00
Dmitry Stogov 27ef344f2b Fixed a possible memory corruption in pack(). Reported by Stefan Esser 2010-05-12 11:04:57 +00:00
Michael Wallner ad15797925 Fixed bug #51725 (xmlrpc_get_type() returns true on invalid dates). (Mike) 2010-05-12 09:37:25 +00:00
Christopher Jones 87b4f2a79d Restructure into PHP/PECL/PEAR component areas (at the expense of duplication) 2010-05-11 18:25:44 +00:00
Dmitry Stogov c2b911a0ec Fixed bug #49893 (Crash while creating an instance of Zend_Mail_Storage_Pop3) 2010-05-11 16:09:43 +00:00
Andrey Hristov d3b7aaa3fc One more time fixing the tests, lets use $IS_MYSQLND which comes from connect.inc 2010-05-11 15:55:07 +00:00
Andrey Hristov d4828ccd23 here comes the news, too 2010-05-11 15:50:21 +00:00
Andrey Hristov ab232ebb09 Fix for mysqli_stmt_execute.phpt, should be ran only against
4.1+ servers. MySQL's SLEEP function is available since 5.0.12, thus
the tests that use this function should be ran only if the server
is at least 5.0.12.
2010-05-11 15:49:03 +00:00
Andrey Hristov fd6f3961f8 These tests should be run only if mysqli uses mysqlnd. Part of fix for
Bug #51712 Test mysql_mysqlnd_read_timeout_long must fail on MySQL4
2010-05-11 15:27:03 +00:00
Raphael Geissert 7d4dde57d9 Document CGI options in the manpage (bug #51718)
Patch by Daniel Egeberg
2010-05-11 15:07:31 +00:00
Ilia Alshanetsky c7a553a7fb Removed double allocation of buffer inside openssl_random_pseudo_bytes() and cleanup code 2010-05-11 14:31:00 +00:00
Dmitry Stogov 57f8649eac Fixed a possible memory corruption in substr_replace() 2010-05-11 11:59:13 +00:00
Dmitry Stogov 5b18acdcc9 Fixed a possible memory corruption because of unexpected call-time pass by refernce and following memory clobbering through callbacks. 2010-05-11 10:41:19 +00:00
Andrey Hristov 962aa93ec7 Fix for bug #51605 (Mysqli zombie links) 2010-05-11 10:03:16 +00:00
Felipe Pena d787d545d2 - Fixed bug #51740 (acinclude.m4 macro PHP_CHECK_SIZEOF is not properly quoted)
Patch by: dave dot mulford at gmail dot com
2010-05-05 21:55:44 +00:00
Rob Richards 1e96fbe4a8 fix bug #48601 (xpath() returns FALSE for legitimate query)
add test
2010-05-05 11:40:11 +00:00
Dmitry Stogov 6597e85562 Fixed bug #50698 (SoapClient should handle wsdls with some incompatiable endpoints). (Justin Dearing) 2010-05-05 07:43:45 +00:00
Rob Richards 617e8a4f8c fix bug #49490 (XPath namespace prefix conflict)
add test
2010-05-04 15:41:49 +00:00
Derick Rethans 7cf3911cb8 - Fixed bug #49081 (DateTime::diff() mistake if start in January and interval >
28 days). (Derick)
2010-05-04 15:11:41 +00:00
Andrey Hristov ebae62d7c4 OOM stability fixes 2010-05-04 14:02:42 +00:00
Andrey Hristov 04d24bde20 Add possibility to control the allocator in when PHP is compiled
with debug
2010-05-04 13:49:43 +00:00
Rob Richards 3860164101 fix bug #51721 (mark DOMNodeList and DOMNamedNodeMap as Traversable) 2010-05-04 12:55:26 +00:00
Adam Harvey e32090a163 Fix misordered news item. 2010-05-04 11:59:54 +00:00
Adam Harvey 73ddb79613 Fix for bug #48289 (iconv_mime_encode() quoted-printable scheme is broken).
Thanks to Hiroaki Kawai for the original patch.
2010-05-04 11:56:59 +00:00
Adam Harvey 9d67273740 Well, as long as we're dealing with typos... :) 2010-05-04 11:01:46 +00:00
Felipe Pena f8b1db2d0d - Fix typo 2010-05-04 10:59:26 +00:00
Pierre Joye af567e7d54 - fix build 2010-05-04 09:51:03 +00:00
Adam Harvey e0e0147003 Alter the getmxrr() test to use lists.php.net (which we presumably control)
instead of ez.no (which we presumably don't) for the single MX record test.
2010-05-04 09:41:47 +00:00
Pierre Joye fdf0395e49 - Fixed bug #51732, Fileinfo __construct or open does not work with NULL 2010-05-04 08:48:58 +00:00
Dmitry Stogov 3a15e98155 Fixed a possible memory corruption in addcslashes(). 2010-05-04 08:02:51 +00:00
Pierre Joye 11040eae16 - revert fix for #51723 in 5.2, vc6 does not support strtoi64, use builtin functioon in 5.3 (trunk is vc9+ only) 2010-05-03 19:51:59 +00:00
Andrey Hristov 6202b46f2a Handle OOM in mysqlnd_res::store_result_fetch_data 2010-05-03 19:32:07 +00:00
Pierre Joye 55320ca1b8 - fix build (declaration must be first) 2010-05-03 19:29:05 +00:00
Andrey Hristov cac3520882 Handle OOM in mysqlnd_fetch_row_buffered_c() 2010-05-03 19:09:45 +00:00
Andrey Hristov 4a8d751cff Handle OOM in mysqlnd_fetch_row_unbuffered_c() 2010-05-03 19:02:48 +00:00
Andrey Hristov d0cef550a3 Handle OOM stemming from mysqlnd_result_init in the same
function and up the stack.
2010-05-03 18:50:47 +00:00
Pierre Joye 43f4d46cb3 - #51273, Content-length header is limited to 32bit integer with apache2/windows 2010-05-03 17:47:58 +00:00
Andrey Hristov 6dff9e55be Handle gracefully OOM in mysqlnd_mempool_create and up the stack 2010-05-03 17:07:18 +00:00
Felipe Pena 44bcdeeb77 - Replaced 'zend_hash_find' to 'zend_hash_quick_find' on zend_hash_compare() function 2010-05-03 16:36:04 +00:00
Andrey Hristov f9fe805abe Handle OOM in block_alloc_get_chunk, and also in the caller
in mysqlnd_wireprotocol.c
2010-05-03 16:20:46 +00:00
Andrey Hristov 864f2da733 Remove unused parameter 2010-05-03 16:09:05 +00:00
Ilia Alshanetsky 813e3cf14d Fixed bug #51690 (Phar::setStub looks for case-sensitive __HALT_COMPILER()) 2010-05-03 14:41:40 +00:00
Pierre Joye cbe5199c42 - WS 2010-05-03 14:29:07 +00:00
Andrey Hristov 88bf630798 One more case to handle in case of OOM, in block_alloc_resize_chunk 2010-05-03 14:26:08 +00:00
Andrey Hristov de4a5156e6 Handle OOM when resizing blocks during data fetch 2010-05-03 14:16:04 +00:00
Andrey Hristov 8fd0407b3a Fix compiler warnings - unused functions 2010-05-03 13:51:30 +00:00
Andrey Hristov d0abd9510e Better handing of OOM in mysqlnd::set_client_option 2010-05-03 13:45:58 +00:00
Pierre Joye 0871df60a3 - update bison version (mike) 2010-05-03 09:05:30 +00:00
Felipe Pena 151fc3b7c0 - Revert accidental changes 2010-05-02 20:11:22 +00:00
Ilia Alshanetsky 90c336026e - Fixed a possible stack exaustion inside fnmatch(). Reporeted by Stefan Esser 2010-05-02 19:34:21 +00:00
Raphael Geissert eca9e10bc0 Fix bug in unaligned memory access fix 2010-05-02 05:01:51 +00:00
Raphael Geissert 803869d6ff Fix unaligned memory accesses in enchant (bug #51289) 2010-05-01 23:32:40 +00:00
Felipe Pena 2b0464c3a9 - Fixed bug #51719 (typo in function prototype) 2010-05-01 18:54:49 +00:00
Raphael Geissert b373d8e184 Fix another typo s/exlcusive/exclusive 2010-05-01 18:30:38 +00:00
Raphael Geissert 174d2528b1 Fix typos s/connnection/connection 2010-05-01 18:27:42 +00:00
Pierre Joye 91bcba0343 - Fix #51688, ini per dir crashes when invalid document root are given 2010-04-30 08:15:09 +00:00
Andrey Hristov a3168a398c Handle OOM cases, in case of persistent connections this is real
and the Zend MM won't help.
2010-04-29 15:49:51 +00:00
Andrey Hristov 2c38266536 Fix valgrind warning, usage of nirvana memory 2010-04-29 15:17:44 +00:00
Andrey Hristov b72437494b Add a test case for the recently fixed memleak 2010-04-29 13:19:57 +00:00
Andrey Hristov fa40847263 Fix possible crashes in case of OOM, as well as a leak. 2010-04-29 13:13:41 +00:00
Andrey Hristov 16e4bd5d58 Try blob columns instead of int, and insert a lot of data at once 2010-04-29 12:07:02 +00:00
Andrey Hristov 9b468d9577 Fix crash if OOM and USE_ZEND_ALLOC=0 2010-04-29 11:49:08 +00:00
Christopher Jones c033a81b50 Bug #51691 (Unnecessary realloc causes crashes in PHP trunk tests with interned strings). Updated tests check some other edge cases 2010-04-29 05:07:16 +00:00
Derick Rethans 9d24798b38 - Updated to version 2010.9 (2010i) 2010-04-28 23:03:36 +00:00
Pierre Joye f4735e72e4 - we don't need that anymore 2010-04-28 22:25:31 +00:00
Christopher Jones 9b3e080098 Mask schemaname in error messages 2010-04-28 17:26:59 +00:00
Andrey Hristov ad4b429633 Fixed few buffer overflows reported by Stefan Esser. 2010-04-28 15:35:52 +00:00
Pierre Joye 0688e6ef01 - - Fixed #51128, imagefill() doesn't work with large images 2010-04-28 14:35:42 +00:00
Pierre Joye 17f5a9d2a2 - fix possible Dechunking Filter Buffer Overflow 2010-04-28 14:10:01 +00:00
Andrey Hristov 1838fcc7b0 const-ify fields 2010-04-28 12:29:13 +00:00
Ilia Alshanetsky 5031bfc395 Fixed a possible arbitrary memory access inside sqlite extension. Reported by Mateusz Kocielski. 2010-04-28 12:10:10 +00:00
Pierre Joye 07446082c8 - Fix #51671, imagefill does not work correctly for small images 2010-04-28 08:23:44 +00:00
Pierre Joye eaab2fbc4b - WS 2010-04-28 08:04:52 +00:00
Ilia Alshanetsky 7174b6ec78 Fixed string format validation inside phar extension. Reported by Stefan Esser 2010-04-27 17:13:24 +00:00
Andrey Hristov 3d900d4cad Fixed very rare memory leak in mysqlnd, when binding thousands of columns 2010-04-27 12:32:34 +00:00
Andrey Hristov eba793fa1f Of course, 64*4 is 256, not 1024 2010-04-27 11:02:51 +00:00
Andrey Hristov be5920b3e9 Move the macro to mysqlnd_enum_n_def.h, because it can be reused
in other places. Also, premultiply the values by 4 and add some
reserve for future releases of the server.
2010-04-27 10:53:27 +00:00
Etienne Kneuss a5d361e3ea Fixed #48361 (SplFileInfo::getPathName() should return the parent 2010-04-27 08:56:01 +00:00
Andrey Hristov 8525f7bb02 Test case for the buffer overflow in mysqlnd_change_user 2010-04-27 08:45:23 +00:00
Andrey Hristov 5bb74e6562 Fixed buffer overflow in mysqlnd_change_user 2010-04-27 08:26:24 +00:00
Hannes Magnusson 3283b811eb - Unifiy that message
- Mention php.ini
2010-04-27 08:23:25 +00:00
Hannes Magnusson 257a192095 Fix test 2010-04-27 08:17:17 +00:00
Andrey Hristov c92c788c85 Fixed possible buffer overflow in mysqlnd_conn__list_fields. 2010-04-27 08:02:08 +00:00
Etienne Kneuss c200eeeb61 Fix #51374 (Wrongly initialized object properties) 2010-04-27 05:58:39 +00:00
Pierrick Charron 8f128b2b13 Fixed bug #51670 getColumnMeta causes segfault when re-executing query after calling nextRowset 2010-04-27 05:56:56 +00:00
Etienne Kneuss 9f16874a53 Fix #49723 (Skip seek when unnecessary) 2010-04-27 04:57:48 +00:00
Kalle Sommer Nielsen cb30330800 Merge safe_mode changes into extensions that are in sync in both branches 2010-04-26 23:55:03 +00:00
Ilia Alshanetsky 64f372fae2 Fixed handling of session variable serialization on certain prefix characters. Reported by Stefan Esser 2010-04-26 18:35:54 +00:00
Pierre Joye 0f88851e92 - Fix #51582, Don't assume UINT64_C it's ever available 2010-04-26 10:34:53 +00:00
Felipe Pena 72ede78ebb - BFN #51624 2010-04-25 23:25:15 +00:00
Hannes Magnusson 267b5cea14 mention which setting! 2010-04-25 18:55:06 +00:00
Etienne Kneuss eb88d58e6c Fix #51532 (Invalid prototype for SplFileInfo::fscanf) 2010-04-25 05:18:42 +00:00
Felipe Pena 1c0ed3433e - Fixed memory leak 2010-04-24 16:59:09 +00:00
Christopher Jones eb0a3ff1af Initialize vars to prevent valgrind warnings in some cases 2010-04-24 00:44:56 +00:00
Andrey Hristov af6dd192b3 Fix for bug #51647 Certificate file without private key (pk in another file) doesn't work 2010-04-23 13:54:40 +00:00
Felipe Pena a5142d18cb - Fixed compiler warnings 2010-04-23 13:32:03 +00:00
Felipe Pena e86710ce11 - Fixed bug #51435 (Missing ifdefs / logic bug in crypt code cause compile errors) 2010-04-22 20:54:35 +00:00
Andrey Hristov 4842f96e2d Change the way the allocator is called - through an abstraction
to give the possibility of pluggability. Thanks to the macros
already used the changes are not pervasive.
2010-04-22 16:28:50 +00:00
Andrey Hristov 5431f235db Fix problem spotted by Felipe. 2010-04-22 16:22:56 +00:00
Antony Dovgal c996aea40d revert most of the Andrey's patch that causes segfaults
(as agreed with Pierre)
2010-04-22 15:59:44 +00:00
Andrey Hristov f71444c756 adding what last commit was missing 2010-04-22 15:14:45 +00:00
Andrey Hristov 34e56fea0b Remove dead code and add possibility to fine tune the size of
a mempool (used for result sets).
2010-04-22 15:07:40 +00:00
Andrey Hristov 2556733787 Add the posibility to switch off the compilation of statistics
collection, for those who want to optimize the last percent of their
binaries.
2010-04-22 13:03:44 +00:00
Antony Dovgal a1f753c8e3 initialize variable. this code still segfaults in OpenSSL, no idea why 2010-04-22 11:56:08 +00:00
Pierre Joye edc961cc66 - Bug #51629, CURLOPT_FOLLOWLOCATION error message is misleading 2010-04-22 11:49:10 +00:00
Pierre Joye 0fecc8c6a0 - Bug #51629, CURLOPT_FOLLOWLOCATION error message is misleading 2010-04-22 08:58:07 +00:00
Adam Harvey 592daf8453 Fix for bug #51604 (newline in end of header is shown in start of message).
Patch by Daniel Egeberg.
2010-04-22 02:22:49 +00:00
Felipe Pena ab81ddd1de - Changed order to FR 2010-04-21 22:30:06 +00:00
Felipe Pena ee185c604a - Fixed bug #51627 (script path not correctly evaluated)
Patch by: russell dot tempero at rightnow dot com
2010-04-21 22:22:31 +00:00
Felipe Pena 5a7786c63f - Fixed bug #51562 (query timeout in mssql can not be changed per query)
Patch by: ejsmont dot artur at gmail dot com
2010-04-21 14:19:27 +00:00
Felipe Pena 45b68febe9 - Fix mem. leak 2010-04-21 12:52:24 +00:00
Andrey Hristov 691522780f Hardening the reads of mysqlnd.
All packets but the row data packet are read into preallocated buffer,
either on the stack or on the heap (cmd_buffer). The size of the buffer
is always checked to skip buffer overruns. Only up to the size of the
buffer is stored into the buffer but packet->header.size has the size of
all data sent. In this case network layer bails.

This patch hardenes the reads, so if packets are malformed and shorter
than they should be there will be no further reads in the buffer.
In short, detection of malformed packets.
2010-04-20 20:02:32 +00:00
Andrey Hristov efa0077e08 put the trigger in the right place 2010-04-20 19:09:56 +00:00
Andrey Hristov 804b950562 It is possible that change user tries an user who has old password.
Instead of error message that doesn't say much there is more information now.
2010-04-20 18:04:24 +00:00
Felipe Pena 0cbfc91628 - Improve test 2010-04-20 16:45:46 +00:00
Felipe Pena df43d76e62 - Fixed bug #51615 (PHP crash with wrong HTML in SimpleXML) 2010-04-20 16:24:21 +00:00
Felipe Pena 1efc049863 - Fixed bug #51607 (pg_copy_from does not allow schema in the tablename argument)
Patch by: cbandy at jbandy dot com
2010-04-20 15:59:01 +00:00
Dmitry Stogov 336e957951 Fixed bug #49700 (memory leaks in php_date.c if garbage collector is enabled) 2010-04-20 15:41:35 +00:00
Felipe Pena 5aedea7179 - Fixed bug #51609 (pg_copy_to: Invalid results when using fourth parameter) 2010-04-20 14:11:53 +00:00
Felipe Pena a175419f84 - Fix copyrights 2010-04-20 13:50:34 +00:00
Antony Dovgal 5d2f7ab843 fix build 2010-04-20 12:50:02 +00:00
Dmitry Stogov 4c252d805d Fixed bug #48781 (Cyclical garbage collector memory leak) 2010-04-20 12:30:35 +00:00
Felipe Pena 0b401e1289 - Fixed bug #51608 (pg_copy_to: WARNING: nonstandard use of \\ in a string literal)
Patch by: cbandy at jbandy dot com
2010-04-20 11:49:23 +00:00
Antony Dovgal 9c97c26832 fix infinite loop in the test 2010-04-20 10:04:26 +00:00
Adam Harvey b47136d332 Added explanatory comments to filter_input and filter_input_array to document
why some code that looks intuitively wrong is actually correct. Related to
bug #51344 (FILTER_NULL_ON_FAILURE flag automatically set in filter_input()
functions).
2010-04-20 04:31:11 +00:00
Stanislav Malyshev 8088be390f fix 64-bit integer overflow in mhash_keygen_s2k 2010-04-20 00:45:07 +00:00
Felipe Pena 45c090f3e7 - Fixed bug #51590 (JSON_ERROR_UTF8 is undefined) 2010-04-18 18:07:27 +00:00
Christopher Jones de174766f8 Add fix made previously 2010-04-16 22:34:25 +00:00
Christopher Jones 7a4b40efc5 Add attribution (thanks Felipe) 2010-04-16 22:06:52 +00:00
Christopher Jones a812818670 Fixed Bug #51577 (Uninitialized memory reference with oci_bind_array_by_name) 2010-04-16 20:36:40 +00:00
Christopher Jones e79a8d440e Merge Kalle's tidy-up from trunk to keep files in sync 2010-04-16 19:47:23 +00:00
Christopher Jones ff515d0ee4 Fix php.ini comment typo 2010-04-15 19:22:01 +00:00
Andrey Hristov 664b2389ca Last batch of int/uint comparison fixes 2010-04-15 15:58:26 +00:00
Andrey Hristov 76d64590b0 More int/uint comparison warning fixes 2010-04-15 15:53:58 +00:00
Andrey Hristov cdac2b4ecf Fix some int/uint comparison warnings 2010-04-15 15:28:00 +00:00
Andrey Hristov 6cc57e0d0d Remove unused file 2010-04-15 15:22:56 +00:00
Andrey Hristov 48e413eb28 more WS 2010-04-15 15:16:29 +00:00
Andrey Hristov 6aa682f564 CS + WS changes 2010-04-15 12:55:04 +00:00
Antony Dovgal 187a0d9b28 final fix for long opts in getopt() 2010-04-15 11:50:43 +00:00
Andrey Hristov dd9fc198ce Fix for bug#49234 method not found ssl_set
Patch was tested and compiles on Windows. (Thanks Kalle)
2010-04-15 11:01:30 +00:00
Antony Dovgal 2404c4c84f discard first TWO symbols of a long argument 2010-04-14 15:49:38 +00:00
Pierre Joye 632c03de71 - #35638, add udate to imap_fetch_overview 2010-04-14 09:45:37 +00:00
Antony Dovgal 913970cebf simplify configure check for nanosleep() 2010-04-13 12:41:46 +00:00
Pierre Joye 036c5f9f31 - begintransaction entry 2010-04-12 19:57:07 +00:00
Ilia Alshanetsky 213e155713 Fixed bug #51512 (mb_send_mail* fail when mail.add_x_header is on by default) 2010-04-12 14:04:45 +00:00
Pierre Joye b298ed5b70 - [doc] merge stream_set_read_buffer, equivalent of stream_set_write_buffer for read operations. Fixing possible bad effects while reading devices 2010-04-12 13:10:05 +00:00
Rob Richards f53f94d24d fix bug #50828 (DOMNotation is not subclass of DOMNode) 2010-04-09 11:34:34 +00:00
Antony Dovgal dda73e99f2 make sure the actual length of the argument passed matches the
length of the argument declared
this fixes things like `php --zend-exten=1` or `php-fpm --fpm-con=conf`
2010-04-08 15:27:21 +00:00
Andrey Hristov 3bd2faff8c Fixint INT_AND_FLOAT_AS native. It was working ok on 64bit but
because on 32bit SIZEOF_LONG is 4 and INT64 from MySQL is 8 everything
was converted to string, even if it was able to put it in a long.
This closes Request #50651 Native type cast returns wrong result
2010-04-08 13:20:37 +00:00
Andrey Hristov be73f948d2 Fixing the second test 2010-04-08 13:18:52 +00:00
Andrey Hristov 48c3d20dd4 one more fix and both work with libmysql and mysqlnd 2010-04-08 10:53:38 +00:00
Antony Dovgal d2699793e0 fix build 2010-04-08 09:56:18 +00:00
Andrey Hristov 8338d48828 Fix for bug #51026 ssl not working 2010-04-08 09:01:21 +00:00
Pierre Joye 517d9bb1f2 - WS 2010-04-08 07:55:35 +00:00
Pierre Joye c4eafddbda - WS 2010-04-08 07:50:05 +00:00
Andrey Hristov 48392f04fa Another fix for the 16 chars user limitation of MySQL 2010-04-07 18:28:46 +00:00
Andrey Hristov 7670d2948d Fix test. The usernames in the server are 16 chars long 2010-04-07 18:05:42 +00:00
Andrey Hristov 798103d4e0 Fix the Windows build (void* arithmetic) as well as --disable-zlib
build.
2010-04-06 18:14:23 +00:00
Andrey Hristov dda0320c5c Stricly C 2010-04-06 14:33:55 +00:00
Antony Dovgal d7e716b8f0 fix typo 2010-04-06 13:42:21 +00:00
Andrey Hristov aa8f43fad9 Recommit with an Windows build fix:
Fix inconsistencies
- memory allocated with spprintf, or likes, outside of mysqlnd's
allocator functions should not be freed by the mysqlnd's allocator
(a wrapper around emalloc/malloc).
- memory allocated by the mysqlnd's allocator should only be freed
  by it.
- add a mode to track memory usage (malloc/free)
2010-04-06 13:28:23 +00:00
Stanislav Malyshev 5f11cd5693 change namespaced ctors - only __construct would work 2010-04-04 23:28:20 +00:00
Felipe Pena 462580cd7d - Fix tests 2010-04-04 17:21:27 +00:00
Felipe Pena 49a81742ef - Fix test 2010-04-04 16:57:44 +00:00
Felipe Pena 4d571dee74 - Fixed tests 2010-04-03 15:42:42 +00:00
Felipe Pena a140e70661 - Fixed bug #51445 (var_dump() invalid/slow *RECURSION* detection) 2010-04-02 21:44:09 +00:00
Rob Richards 0758c8794d fix bug #48983 (DomDocument : saveHTMLFile wrong charset) 2010-04-02 20:08:15 +00:00
Rasmus Lerdorf 9744284109 Fix tests 2010-04-02 18:27:48 +00:00
Rasmus Lerdorf 6d77506cfd Update the FILTER_VALIDATE_EMAIL filter to fix bug #49576 2010-04-02 17:56:37 +00:00
Rob Richards f1af56fb4e fix WS 2010-04-02 16:19:23 +00:00
Rob Richards 12b71200be re-apply bug fix #35673 (formatOutput does not work with saveHTML) from old trunk
add test
BFN
2010-04-02 16:15:06 +00:00
Stanislav Malyshev 44a5b8e459 fix #49192 - crash in GC when get_properties handler returns null 2010-04-01 22:54:03 +00:00
Pierre Joye 96e2651fa2 - revert revision 297277, break the builds (declaration must go 1st, size of void * and other known situations). Also Johannes, can you check that commit pls? Thought we were in bugs fixing only for 5.3 2010-04-01 20:21:50 +00:00
Stanislav Malyshev a3857fd963 fix #51394 - try harder to find script lineno when exception happens 2010-04-01 19:36:56 +00:00
Rasmus Lerdorf 8b1d84a6ce Add new full_special_chars filter to tests 2010-04-01 18:04:57 +00:00
Andrey Hristov f534df710e Fix inconsistencies
- memory allocated with spprintf, or likes, outside of mysqlnd's
allocator functions should not be freed by the mysqlnd's allocator
(a wrapper around emalloc/malloc).
- memory allocated by the mysqlnd's allocator should only be freed
  by it.
- add a mode to track memory usage (malloc/free)
2010-04-01 13:26:41 +00:00
Andrey Hristov a712d9cefb Better fix for bug #51347 mysqli_close / connection memory leak 2010-04-01 12:46:21 +00:00
Ilia Alshanetsky c2e16d3c5b On beginTransaction() reset error state 2010-04-01 12:08:55 +00:00
Andrey Hristov 311ab2c822 Fixed bug #51347 mysqli_close / connection memory leak
Streams API registers every stream as resource, which lands then
in EG(regular_list), however doesn't clean that when the stream is
closed. At the end this is a para-leak. At the end of the script
all memory is cleaned, however this is a problem for long runnig
scripts that open connections. For every opened and closed connection
about 150 Bytes on 32bit and 250 Bytes on 64bit will be "lost",
according to memory_get_usage().
2010-04-01 11:50:24 +00:00
Pierre Joye 60176163f1 - fix build 2010-04-01 10:34:05 +00:00
Rasmus Lerdorf b529350d4a Fix FILTER_VALIDATE_URL - Host names can't start with '.' or '-' 2010-03-31 23:56:30 +00:00
Rasmus Lerdorf a5b5743d71 full_special_chars filter from trunk - approved by johannes 2010-03-31 22:59:09 +00:00
Johannes Schlüter 53d35553c6 It's 2010 already 2010-03-30 21:09:07 +00:00
Johannes Schlüter 4dc1cef4fe Use php_error_docref instead of zend_error 2010-03-30 21:02:32 +00:00
Ilia Alshanetsky 658fe1d0c3 Upgraded bundled sqlite to version 3.6.23.1 2010-03-30 11:52:25 +00:00
Derick Rethans 462399b78b - Updated to version 2010.7 (2010g) 2010-03-29 17:22:53 +00:00
Andrey Hristov 94cd357f5b Make it coupled - what is allocated with mnd_ should be freed
with mnd_ and vice versa.
Added mnd_pestrndup and mnd_pestrdup, which wrap the normal
calls to be able to track this calls.
Fixed some failing tests.
2010-03-29 17:04:16 +00:00
Ilia Alshanetsky e99039d692 Upgraded bundled PCRE to version 8.02. 2010-03-29 11:58:06 +00:00
Christopher Jones 3e58dee19a Fix #51220 by adding . Also improve reliability for tests using undefined behavior. 2010-03-26 19:38:26 +00:00
Andrey Hristov ec36ac1610 Fix tests that fail when the MySQL's socket file is not /tmp/mysql.sock
as it is in when compiled from source and the default for mysqlnd.
SuSE for example uses /var/run/mysql/mysql.sock . Also, sql.safe_mode
(ext/mysql and ingres) needs the socket.
Fix possible crashes in mysqlnd. When packets are shorter, functions should
return error.
2010-03-26 16:58:25 +00:00
Adam Harvey 53cfb3d53d Fixed bug #51393 (DateTime::createFromFormat() fails if format string contains timezone). 2010-03-26 04:31:26 +00:00
Stanislav Malyshev 252082192a fix the protos 2010-03-25 19:17:17 +00:00
Christopher Jones 1a6f4efbad Fixed bug #51291 (oci_error doesn't report last error when called two times) 2010-03-24 22:08:55 +00:00
Hannes Magnusson abd893a2ae Fix tests 2010-03-24 22:06:21 +00:00
Hannes Magnusson a1cce74e96 Fix test (the key can be negative) 2010-03-24 21:57:30 +00:00
Andrey Hristov 78887ff757 Fix a segfault when using a mysqli object after unsuccesssful connect, the
handle should have been allocated with mysqli_init().
2010-03-24 15:17:57 +00:00
Andrey Hristov 9f20131311 fix build failure after recent commit by Kalle 2010-03-24 10:06:42 +00:00
Takeshi Abe a46e108b83 Fixed bug #51263 (imagettftext and rotated text uses wrong baseline) 2010-03-24 04:12:19 +00:00
1025 changed files with 73590 additions and 46561 deletions

No files matched your search

-14191
View File
File diff suppressed because it is too large. Load diff
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
+6
View File
@@ -73,6 +73,12 @@ PRIMARY MAINTAINER: Edin Kadribasic <edink@php.net>
MAINTENANCE: Maintained
STATUS: Working
-------------------------------------------------------------------------------
EXTENSION: fpm
PRIMARY MAINTAINER: Antony Dovgal <tony2001@php.net>, Jerome Loyet <fat@php.net>
MAINTENANCE: Maintained
STATUS: Working
SINCE: 5.3.3
-------------------------------------------------------------------------------
EXTENSION: isapi
MAINTENANCE: Unknown
STATUS: Working
+24 -12
View File
@@ -279,7 +279,15 @@ ir if
it is your first install then you need to "make install" as well)
13. cd ../php-5.x.y
14. cp php.ini-dist /usr/local/lib/php.ini
14. The PHP distribution provides two sample php.ini files, you can use them
by
cp php.ini-development /usr/local/lib/php.ini
or
cp php.ini-production /usr/local/lib/php.ini
If you choose one of these php.ini files be certain to read the list
of changes within, as they affect how PHP behaves.
15. You can edit /usr/local/lib/php.ini file to set PHP options.
Edit your httpd.conf or srm.conf file and add:
@@ -451,15 +459,19 @@ Apache 2.0 on Unix systems
13. Setup your php.ini
cp php.ini-dist /usr/local/lib/php.ini
The PHP distribution provides two sample php.ini files, you can use them
by
cp php.ini-development /usr/local/lib/php.ini
or
cp php.ini-production /usr/local/lib/php.ini
If you choose one of these php.ini files be certain to read the list
of changes within, as they affect how PHP behaves.
You may edit your .ini file to set PHP options. If you prefer having
php.ini in another location, use --with-config-file-path=/some/path in
step 10.
If you instead choose php.ini-recommended, be certain to read the list
of changes within, as they affect how PHP behaves.
14. Edit your httpd.conf to load the PHP module. The path on the right hand
side of the LoadModule statement must point to the path of the PHP
module on your system. The make install from above may have already
@@ -858,7 +870,7 @@ Using Binary Packages
Example 2-6. OpenBSD Package Install Example
# pkg_add php4-core-4.3.8.tgz
# /usr/local/sbin/phpxs -s
# cp /usr/local/share/doc/php4/php.ini-recommended /var/www/conf/php.ini
# cp /usr/local/share/doc/php4/php.ini-development /var/www/conf/php.ini
(add in mysql)
# pkg_add php4-mysql-4.3.8.tgz
# /usr/local/sbin/phpxs -a mysql
@@ -1242,10 +1254,10 @@ setenv OPTIM=-O2
back to the root of the Apache source directory and run the above
configure command again. That'll bring the link table up to date.
Run make and make install again.
7. Copy and rename the php.ini-dist file to your bin directory from
your PHP 4 source directory: cp php.ini-dist /usr/local/bin/php.ini
or (if your don't have a local directory) cp php.ini-dist
/usr/bin/php.ini.
7. Copy and rename the php.ini-development or php.ini-production file to
your bin directory from your PHP 4 source directory:
cp php.ini-development /usr/local/bin/php.ini or (if your don't have a
local directory) cp php.ini-development /usr/bin/php.ini.
__________________________________________________________________
Compiling for MacOS X Client
@@ -1735,8 +1747,8 @@ cgi error:
example, set it with something like:
--with-config-file-path=/etc
And then you would copy php.ini-dist from the distribution to
/etc/php.ini and edit it to make any local changes you want.
And then you would copy php.ini-development or php.ini-production from the
distribution to /etc/php.ini and edit it to make any local changes you want.
--with-config-file-scan-dir=PATH
On Windows the default path for the php.ini file is the Windows
+1 -1
View File
@@ -1,6 +1,6 @@
--------------------------------------------------------------------
The PHP License, version 3.01
Copyright (c) 1999 - 2009 The PHP Group. All rights reserved.
Copyright (c) 1999 - 2010 The PHP Group. All rights reserved.
--------------------------------------------------------------------
Redistribution and use in source and binary forms, with or without
+3 -18
View File
@@ -5,24 +5,7 @@
lcov: lcov-html
lcov-test: all
@echo "Running test suite"
@find . -name \*.gcda -o -name \*.da -o -name \*.bbg? | xargs rm -f
-@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
NO_INTERACTION=1 \
TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
TEST_PHP_SRCDIR=$(top_srcdir) \
CC="$(CC)" \
$(PHP_EXECUTABLE) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -d 'extension_dir=modules/' -d `( . $(PHP_MODULES) ; echo extension=$$dlname)` tests/; \
elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
NO_INTERACTION=1 \
TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
TEST_PHP_SRCDIR=$(top_srcdir) \
CC="$(CC)" \
$(top_builddir)/$(SAPI_CLI_PATH) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php $(TESTS); \
else \
echo "ERROR: Cannot run tests without CLI sapi."; \
fi
lcov-test: lcov-clean-data test
php_lcov.info: lcov-test
@echo "Generating data for $@"
@@ -77,3 +60,5 @@ lcov-clean:
rm -rf lcov_data/
rm -rf lcov_html/
lcov-clean-data:
@find . -name \*.gcda -o -name \*.da -o -name \*.bbg? | xargs rm -f
+1
View File
@@ -98,6 +98,7 @@ test: all
TEST_PHP_SRCDIR=$(top_srcdir) \
CC="$(CC)" \
$(PHP_EXECUTABLE) -n -c $(top_builddir)/tmp-php.ini $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n -c $(top_builddir)/tmp-php.ini -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
rm $(top_builddir)/tmp-php.ini; \
else \
echo "ERROR: Cannot run tests without CLI sapi."; \
fi
+620 -30
View File
@@ -1,16 +1,554 @@
PHP NEWS
PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
?? ??? 20??, PHP 5.3.3
- Upgraded bundled PCRE to version 8.01. (Ilia)
09 Dec 2010, PHP 5.3.4
- Upgraded bundled Sqlite3 to version 3.7.3. (Ilia)
- Upgraded bundled PCRE to version 8.10. (Ilia)
- Security enhancements:
. Fixed crash in zip extract method (possible CWE-170).
(Maksymilian Arciemowicz, Pierre)
. Paths with NULL in them (foo\0bar.txt) are now considered as invalid. (Rasmus)
. Fixed a possible double free in imap extension (Identified by Mateusz
Kocielski). (CVE-2010-4150). (Ilia)
. Fixed NULL pointer dereference in ZipArchive::getArchiveComment.
(CVE-2010-3709). (Maksymilian Arciemowicz)
. Fixed possible flaw in open_basedir (CVE-2010-3436). (Pierre)
. Fixed MOPS-2010-24, fix string validation. (CVE-2010-2950). (Pierre)
. Fixed symbolic resolution support when the target is a DFS share. (Pierre)
. Fixed bug #52929 (Segfault in filter_var with FILTER_VALIDATE_EMAIL with
large amount of data) (CVE-2010-3710). (Adam)
- General improvements:
. Added stat support for zip stream. (Pierre)
. Added follow_location (enabled by default) option for the http stream
support. (Pierre)
. Improved support for is_link and related functions on Windows. (Pierre)
. Added a 3rd parameter to get_html_translation_table. It now takes a charset
hint, like htmlentities et al. (Gustavo)
- Implemented feature requests:
. Implemented FR #52348, added new constant ZEND_MULTIBYTE to detect
zend multibyte at runtime. (Kalle)
. Implemented FR #52173, added functions pcntl_get_last_error() and
pcntl_strerror(). (nick dot telford at gmail dot com, Arnaud)
. Implemented symbolic links support for open_basedir checks. (Pierre)
. Implemented FR #51804, SplFileInfo::getLinkTarget on Windows. (Pierre)
. Implemented FR #50692, not uploaded files don't count towards
max_file_uploads limit. As a side improvement, temporary files are not opened
for empty uploads and, in debug mode, 0-length uploads. (Gustavo)
- Improved MySQLnd:
. Added new character sets to mysqlnd, which are available in MySQL 5.5
(Andrey)
- Improved PHP-FPM SAPI:
. Added '-p/--prefix' to php-fpm to use a custom prefix and run multiple
instances. (fat)
. Added custom process title for FPM. (fat)
. Added '-t/--test' to php-fpm to check and validate FPM conf file. (fat)
. Added statistics about listening socket queue length for FPM.
(andrei dot nigmatulin at gmail dot com, fat)
- Core:
. Fixed extract() to do not overwrite $GLOBALS and $this when using
EXTR_OVERWRITE. (jorto at redhat dot com)
. Fixed bug in the Windows implementation of dns_get_record, where the two
last parameters wouldn't be filled unless the type were DNS_ANY (Gustavo).
. Changed the $context parameter on copy() to actually have an effect. (Kalle)
. Fixed htmlentities/htmlspecialchars accepting certain ill-formed UTF-8
sequences. (Gustavo)
. Fixed bug #53409 (sleep() returns NULL on Windows). (Pierre)
. Fixed bug #53319 (strip_tags() may strip '<br />' incorrectly). (Felipe)
. Fixed bug #53304 (quot_print_decode does not handle lower-case hex digits).
(Ilia, daniel dot mueller at inexio dot net)
. Fixed bug #53248 (rawurlencode RFC 3986 EBCDIC support misses tilde char).
(Justin Martin)
. Fixed bug #53226 (file_exists fails on big filenames). (Adam)
. Fixed bug #53198 (changing INI setting "from" with ini_set did not have any
effect). (Gustavo)
. Fixed bug #53180 (post_max_size=0 not disabling the limit when the content
type is application/x-www-form-urlencoded or is not registered with PHP).
(gm at tlink dot de, Gustavo)
. Fixed bug #53141 (autoload misbehaves if called from closing session).
(ladislav at marek dot su)
. Fixed bug #53021 (In html_entity_decode, failure to convert numeric entities
with ENT_NOQUOTES and ISO-8859-1). Fixed and extended the fix of ENT_NOQUOTES
in html_entity_decode that had introduced the bug (rev #185591) to other
encodings. Additionaly, html_entity_decode() now doesn't decode &#34; if
ENT_NOQUOTES is given. (Gustavo)
. Fixed bug #52931 (strripos not overloaded with function overloading enabled).
(Felipe)
. Fixed bug #52772 (var_dump() doesn't check for the existence of
get_class_name before calling it). (Kalle, Gustavo)
. Fixed bug #52534 (var_export array with negative key). (Felipe)
. Fixed bug #52327 (base64_decode() improper handling of leading padding in
strict mode). (Ilia)
. Fixed bug #52260 (dns_get_record fails with non-existing domain on Windows).
(a_jelly_doughnut at phpbb dot com, Pierre)
. Fixed bug #50953 (socket will not connect to IPv4 address when the host has
both IPv4 and IPv6 addresses, on Windows). (Gustavo, Pierre)
. Fixed bug #50524 (proc_open on Windows does not respect cwd as it does on
other platforms). (Pierre)
. Fixed bug #49687 (utf8_decode vulnerabilities and deficiencies in the number
of reported malformed sequences). (CVE-2010-3870) (Gustavo)
. Fixed bug #49407 (get_html_translation_table doesn't handle UTF-8). (Gustavo)
. Fixed bug #48831 (php -i has different output to php --ini). (Richard,
Pierre)
. Fixed bug #47643 (array_diff() takes over 3000 times longer than php 5.2.4).
(Felipe)
. Fixed bug #47168 (printf of floating point variable prints maximum of 40
decimal places). (Ilia)
. Fixed bug #46587 (mt_rand() does not check that max is greater than min).
(Ilia)
. Fixed bug #29085 (bad default include_path on Windows). (Pierre)
. Fixed bug #25927 (get_html_translation_table calls the ' &#39; instead of
&#039;). (Gustavo)
- Zend engine:
. Reverted fix for bug #51176 (Static calling in non-static method behaves
like $this->). (Felipe)
. Changed deprecated ini options on startup from E_WARNING to E_DEPRECATED.
(Kalle)
. Fixed NULL dereference in lex_scan on zend multibyte builds where the script
had a flex incompatible encoding and there was no converter. (Gustavo)
. Fixed covariance of return-by-ref constraints. (Etienne)
. Fixed bug #53305 (E_NOTICE when defining a constant starts with
__COMPILER_HALT_OFFSET__). (Felipe)
. Fixed bug #52939 (zend_call_function does not respect ZEND_SEND_PREFER_REF).
(Dmitry)
. Fixed bug #52879 (Objects unreferenced in __get, __set, __isset or __unset
can be freed too early). (mail_ben_schmidt at yahoo dot com dot au, Dmitry)
. Fixed bug #52786 (PHP should reset section to [PHP] after ini sections).
(Fedora at famillecollet dot com)
. Fixed bug #52508 (newline problem with parse_ini_file+INI_SCANNER_RAW).
(Felipe)
. Fixed bug #52484 (__set() ignores setting properties with empty names).
(Felipe)
. Fixed bug #52361 (Throwing an exception in a destructor causes invalid
catching). (Dmitry)
. Fixed bug #51008 (Zend/tests/bug45877.phpt fails). (Dmitry)
- Build issues:
. Fixed bug #52436 (Compile error if systems do not have stdint.h)
(Sriram Natarajan)
. Fixed bug #50345 (nanosleep not detected properly on some solaris versions).
(Ulf, Tony)
. Fixed bug #49215 (make fails on glob_wrapper). (Felipe)
- Calendar extension:
. Fixed bug #52744 (cal_days_in_month incorrect for December 1 BCE).
(gpap at internet dot gr, Adam)
- cURL extension:
. Fixed bug #52828 (curl_setopt does not accept persistent streams).
(Gustavo, Ilia)
. Fixed bug #52827 (cURL leaks handle and causes assertion error
(CURLOPT_STDERR)). (Gustavo)
. Fixed bug #52202 (CURLOPT_PRIVATE gets corrupted). (Ilia)
. Fixed bug #50410 (curl extension slows down PHP on Windows). (Pierre)
- DateTime extension:
. Fixed bug #53297 (gettimeofday implementation in php/win32/time.c can return
1 million microsecs). (ped at 7gods dot org)
. Fixed bug #52668 (Iterating over a dateperiod twice is broken). (Derick)
. Fixed bug #52454 (Relative dates and getTimestamp increments by one day).
(Derick)
. Fixed bug #52430 (date_parse parse 24:xx:xx as valid time). (Derick)
. Added support for the ( and ) delimiters/separators to
DateTime::createFromFormat(). (Derick)
- DBA extension:
. Added Berkeley DB 5.1 support to the DBA extension. (Oracle Corp.)
- DOM extension:
. Fixed bug #52656 (DOMCdataSection does not work with splitText). (Ilia)
- Filter extension:
. Fixed the filter extension accepting IPv4 octets with a leading 0 as that
belongs to the unsupported "dotted octal" representation. (Gustavo)
. Fixed bug #53236 (problems in the validation of IPv6 addresses with leading
and trailing :: in the filter extension). (Gustavo)
. Fixed bug #50117 (problems in the validation of IPv6 addresses with IPv4
addresses and ::). (Gustavo)
- GD extension:
. Fixed bug #53492 (fix crash if anti-aliasing steps are invalid). (Pierre)
- GMP extension:
. Fixed bug #52906 (gmp_mod returns negative result when non-negative is
expected). (Stas)
. Fixed bug #52849 (GNU MP invalid version match). (Adam)
- Hash extension:
. Fixed bug #51003 (unaligned memory access in ext/hash/hash_tiger.c).
(Mike, Ilia)
- Iconv extension:
. Fixed bug #52941 (The 'iconv_mime_decode_headers' function is skipping
headers). (Adam)
. Fixed bug #52599 (iconv output handler outputs incorrect content type
when flags are used). (Ilia)
. Fixed bug #51250 (iconv_mime_decode() does not ignore malformed Q-encoded
words). (Ilia)
- Intl extension:
. Fixed crashes on invalid parameters in intl extension. (CVE-2010-4409). (Stas, Maksymilian
Arciemowicz)
. Added support for formatting the timestamp stored in a DateTime object.
(Stas)
. Fixed bug #50590 (IntlDateFormatter::parse result is limited to the integer
range). (Stas)
- Mbstring extension:
. Fixed bug #53273 (mb_strcut() returns garbage with the excessive length
parameter). (CVE-2010-4156) (Mateusz Kocielski, Pierre, Moriyoshi)
. Fixed bug #52981 (Unicode casing table was out-of-date. Updated with
UnicodeData-6.0.0d7.txt and included the source of the generator program with
the distribution) (Gustavo).
. Fixed bug #52681 (mb_send_mail() appends an extra MIME-Version header).
(Adam)
- MSSQL extension:
. Fixed possible crash in mssql_fetch_batch(). (Kalle)
. Fixed bug #52843 (Segfault when optional parameters are not passed in to
mssql_connect). (Felipe)
- MySQL extension:
. Fixed bug #52636 (php_mysql_fetch_hash writes long value into int).
(Kalle, rein at basefarm dot no)
- MySQLi extension:
. Fixed bug #52891 (Wrong data inserted with mysqli/mysqlnd when using
mysqli_stmt_bind_param and value> PHP_INT_MAX). (Andrey)
. Fixed bug #52686 (mysql_stmt_attr_[gs]et argument points to incorrect type).
(rein at basefarm dot no)
. Fixed bug #52654 (mysqli doesn't install headers with structures it uses).
(Andrey)
. Fixed bug #52433 (Call to undefined method mysqli::poll() - must be static).
(Andrey)
. Fixed bug #52417 (MySQLi build failure with mysqlnd on MacOS X). (Andrey)
. Fixed bug #52413 (MySQLi/libmysql build failure on OS X, FreeBSD). (Andrey)
. Fixed bug #52390 (mysqli_report() should be per-request setting). (Kalle)
. Fixed bug #52302 (mysqli_fetch_all does not work with MYSQLI_USE_RESULT).
(Andrey)
. Fixed bug #52221 (Misbehaviour of magic_quotes_runtime (get/set)). (Andrey)
. Fixed bug #45921 (Can't initialize character set hebrew). (Andrey)
- MySQLnd:
. Fixed bug #52613 (crash in mysqlnd after hitting memory limit). (Andrey)
- ODBC extension:
- Fixed bug #52512 (Broken error handling in odbc_execute).
(mkoegler at auto dot tuwien dot ac dot at)
- Openssl extension:
. Fixed possible blocking behavior in openssl_random_pseudo_bytes on Windows.
(Pierre)
. Fixed bug #53136 (Invalid read on openssl_csr_new()). (Felipe)
. Fixed bug #52947 (segfault when ssl stream option capture_peer_cert_chain
used). (Felipe)
- Oracle Database extension (OCI8):
. Fixed bug #53284 (Valgrind warnings in oci_set_* functions) (Oracle Corp.)
. Fixed bug #51610 (Using oci_connect causes PHP to take a long time to
exit). Requires Oracle 11.2.0.2 client libraries (or Oracle bug fix
9891199) for this patch to have an effect. (Oracle Corp.)
- PCNTL extension:
. Fixed bug #52784 (Race condition when handling many concurrent signals).
(nick dot telford at gmail dot com, Arnaud)
- PCRE extension:
. Fixed bug #52971 (PCRE-Meta-Characters not working with utf-8). (Felipe)
. Fixed bug #52732 (Docs say preg_match() returns FALSE on error, but it
returns int(0)). (slugonamission at gmail dot com)
- PHAR extension:
. Fixed bug #50987 (unaligned memory access in phar.c).
(geissert at debian dot org, Ilia)
- PHP-FPM SAPI:
. Fixed bug #53412 (segfault when using -y). (fat)
. Fixed inconsistent backlog default value (-1) in FPM on many systems. (fat)
. Fixed bug #52501 (libevent made FPM crashed when forking -- libevent has
been removed). (fat)
. Fixed bug #52725 (gcc builtin atomic functions were sometimes used when they
were not available). (fat)
. Fixed bug #52693 (configuration file errors are not logged to stderr). (fat)
. Fixed bug #52674 (FPM Status page returns inconsistent Content-Type headers).
(fat)
. Fixed bug #52498 (libevent was not only linked to php-fpm). (fat)
- PDO:
. Fixed bug #52699 (PDO bindValue writes long int 32bit enum).
(rein at basefarm dot no)
. Fixed bug #52487 (PDO::FETCH_INTO leaks memory). (Felipe)
- PDO DBLib driver:
. Fixed bug #52546 (pdo_dblib segmentation fault when iterating MONEY values).
(Felipe)
- PDO Firebird driver:
. Restored firebird support (VC9 builds only). (Pierre)
. Fixed bug #53335 (pdo_firebird did not implement rowCount()).
(preeves at ibphoenix dot com)
. Fixed bug #53323 (pdo_firebird getAttribute() crash).
(preeves at ibphoenix dot com)
- PDO MySQL driver:
. Fixed bug #52745 (Binding params doesn't work when selecting a date inside a
CASE-WHEN). (Andrey)
- PostgreSQL extension:
. Fixed bug #47199 (pg_delete() fails on NULL). (ewgraf at gmail dot com)
- Reflection extension:
. Fixed ReflectionProperty::isDefault() giving a wrong result for properties
obtained with ReflectionClass::getProperties(). (Gustavo)
- Reflection extension:
. Fixed bug #53366 (Reflection doesnt get dynamic property value from
getProperty()). (Felipe)
. Fixed bug #52854 (ReflectionClass::newInstanceArgs does not work for classes
without constructors). (Johannes)
- SOAP extension:
. Fixed bug #44248 (RFC2616 transgression while HTTPS request through proxy
with SoapClient object). (Dmitry)
- SPL extension:
. Fixed bug #53362 (Segmentation fault when extending SplFixedArray). (Felipe)
. Fixed bug #53279 (SplFileObject doesn't initialise default CSV escape
character). (Adam)
. Fixed bug #53144 (Segfault in SplObjectStorage::removeAll()). (Felipe)
. Fixed bug #53071 (SPLObjectStorage defeats gc_collect_cycles). (Gustavo)
. Fixed bug #52573 (SplFileObject::fscanf Segmentation fault). (Felipe)
. Fixed bug #51763 (SplFileInfo::getType() does not work symbolic link
and directory). (Pierre)
. Fixed bug #50481 (Storing many SPLFixedArray in an array crashes). (Felipe)
. Fixed bug #50579 (RegexIterator::REPLACE doesn't work). (Felipe)
- SQLite3 extension:
. Fixed bug #53463 (sqlite3 columnName() segfaults on bad column_number).
(Felipe)
- Streams:
. Fixed forward stream seeking emulation in streams that don't support seeking
in situations where the read operation gives back less data than requested
and when there was data in the buffer before the emulation started. Also made
more consistent its behavior -- should return failure every time less data
than was requested was skipped. (Gustavo)
. Fixed bug #53241 (stream casting that relies on fdopen/fopencookie fails
with streams opened with, inter alia, the 'xb' mode). (Gustavo)
. Fixed bug #53006 (stream_get_contents has an unpredictable behavior when the
underlying stream does not support seeking). (Gustavo)
. Fixed bug #52944 (Invalid write on second and subsequent reads with an
inflate filter fed invalid data). (Gustavo)
. Fixed bug #52820 (writes to fopencookie FILE* not commited when seeking the
stream). (Gustavo)
- WDDX extension:
. Fixed bug #52468 (wddx_deserialize corrupts integer field value when left
empty). (Felipe)
- Zlib extension:
. Fixed bug #52926 (zlib fopen wrapper does not use context). (Gustavo)
22 Jul 2010, PHP 5.3.3
- Upgraded bundled sqlite to version 3.6.23.1. (Ilia)
- Upgraded bundled PCRE to version 8.02. (Ilia)
- Added support for JSON_NUMERIC_CHECK option in json_encode() that converts
numeric strings to integers. (Ilia)
- Added stream_set_read_buffer, allows to set the buffer for read operation.
(Pierre)
- Added stream filter support to mcrypt extension (ported from
mcrypt_filter). (Stas)
- Added full_special_chars filter to ext/filter. (Rasmus)
- Added backlog socket context option for stream_socket_server(). (Mike)
- Added fifth parameter to openssl_encrypt()/openssl_decrypt()
(string $iv) to use non-NULL IV.
Made implicit use of NULL IV a warning. (Sara)
- Added openssl_cipher_iv_length(). (Sara)
- Added FastCGI Process Manager (FPM) SAPI. (Tony)
- Added recent Windows versions to php_uname and fix undefined windows
version support. (Pierre)
- Added Berkeley DB 5 support to the DBA extension. (Johannes, Chris Jones)
- Added support for copy to/from array/file for pdo_pgsql extension.
(Denis Gasparin, Ilia)
- Added inTransaction() method to PDO, with specialized support for Postgres.
(Ilia, Denis Gasparin)
- Changed namespaced classes so that the ctor can only be named
__construct now. (Stas)
- Reset error state in PDO::beginTransaction() reset error state. (Ilia)
- Implemented FR#51295 (SQLite3::busyTimeout not existing). (Mark)
- Implemented FR#35638 (Adding udate to imap_fetch_overview results).
(Charles_Duffy at dell dot com )
- Rewrote var_export() to use smart_str rather than output buffering, prevents
data disclosure if a fatal error occurs (CVE-2010-2531). (Scott)
- Fixed possible buffer overflows in mysqlnd_list_fields, mysqlnd_change_user.
(Andrey)
- Fixed possible buffer overflows when handling error packets in mysqlnd.
Reported by Stefan Esser. (Andrey)
- Fixed very rare memory leak in mysqlnd, when binding thousands of columns.
(Andrey)
- Fixed a crash when calling an inexistent method of a class that inherits
PDOStatement if instantiated directly instead of doing by the PDO methods.
(Felipe)
- Fixed memory leak on error in mcrypt_create_iv on Windows. (Pierre)
- Fixed a possible crash because of recursive GC invocation. (Dmitry)
- Fixed a possible resource destruction issues in shm_put_var().
Reported by Stefan Esser. (Dmitry)
- Fixed a possible information leak because of interruption of XOR operator.
Reported by Stefan Esser. (Dmitry)
- Fixed a possible memory corruption because of unexpected call-time pass by
refernce and following memory clobbering through callbacks.
Reported by Stefan Esser. (Dmitry)
- Fixed a possible memory corruption in ArrayObject::uasort(). Reported by
Stefan Esser. (Dmitry)
- Fixed a possible memory corruption in parse_str(). Reported by Stefan Esser.
(Dmitry)
- Fixed a possible memory corruption in pack(). Reported by Stefan Esser.
(Dmitry)
- Fixed a possible memory corruption in substr_replace(). Reported by Stefan
Esser. (Dmitry)
- Fixed a possible memory corruption in addcslashes(). Reported by Stefan
Esser. (Dmitry)
- Fixed a possible stack exhaustion inside fnmatch(). Reported by Stefan
Esser. (Ilia)
- Fixed a possible dechunking filter buffer overflow. Reported by Stefan Esser.
(Pierre)
- Fixed a possible arbitrary memory access inside sqlite extension. Reported
by Mateusz Kocielski. (Ilia)
- Fixed string format validation inside phar extension. Reported by Stefan
Esser. (Ilia)
- Fixed handling of session variable serialization on certain prefix
characters. Reported by Stefan Esser. (Ilia)
- Fixed a NULL pointer dereference when processing invalid XML-RPC
requests (Fixes CVE-2010-0397, bug #51288). (Raphael Geissert)
- Fixed 64-bit integer overflow in mhash_keygen_s2k(). (Clément LECIGNE, Stas)
- Fixed SplObjectStorage unserialization problems (CVE-2010-2225). (Stas)
- Fixed the mail.log ini setting when no filename was given. (Johannes)
- Fixed bug #52317 (Segmentation fault when using mail() on a rhel 4.x (only 64
bit)). (Adam)
- Fixed bug #52262 (json_decode() shows no errors on invalid UTF-8).
(Scott)
- Fixed bug #52240 (hash_copy() does not copy the HMAC key, causes wrong
results and PHP crashes). (Felipe)
- Fixed bug #52238 (Crash when an Exception occured in iterator_to_array).
(Johannes)
- Fixed bug #52193 (converting closure to array yields empty array). (Felipe)
- Fixed bug #52183 (Reflectionfunction reports invalid number of arguments for
function aliases). (Felipe)
- Fixed bug #52162 (custom request header variables with numbers are removed).
(Sriram Natarajan)
- Fixed bug #52160 (Invalid E_STRICT redefined constructor error). (Felipe)
- Fixed bug #52138 (Constants are parsed into the ini file for section names).
(Felipe)
- Fixed bug #52115 (mysqli_result::fetch_all returns null, not an empty array).
(Andrey)
- Fixed bug #52101 (dns_get_record() garbage in 'ipv6' field on Windows).
(Pierre)
- Fixed bug #52082 (character_set_client & character_set_connection reset after
mysqli_change_user()). (Andrey)
- Fixed bug #52043 (GD doesn't recognize latest libJPEG versions).
(php at group dot apple dot com, Pierre)
- Fixed bug #52041 (Memory leak when writing on uninitialized variable returned
from function). (Dmitry)
- Fixed bug #52060 (Memory leak when passing a closure to method_exists()).
(Felipe)
- Fixed bug #52057 (ReflectionClass fails on Closure class). (Felipe)
- Fixed bug #52051 (handling of case sensitivity of old-style constructors
changed in 5.3+). (Felipe)
- Fixed bug #52037 (Concurrent builds fail in install-programs). (seanius at
debian dot org, Kalle)
- Fixed bug #52019 (make lcov doesn't support TESTS variable anymore). (Patrick)
- Fixed bug #52010 (open_basedir restrictions mismatch on vacuum command).
(Ilia)
- Fixed bug #52001 (Memory allocation problems after using variable variables).
(Dmitry)
- Fixed bug #51991 (spl_autoload and *nix support with namespace). (Felipe)
- Fixed bug #51943 (AIX: Several files are out of ANSI spec). (Kalle,
coreystup at gmail dot com)
- Fixed bug #51911 (ReflectionParameter::getDefaultValue() memory leaks with
constant array). (Felipe)
- Fixed bug #51905 (ReflectionParameter fails if default value is an array
with an access to self::). (Felipe)
- Fixed bug #51899 (Parse error in parse_ini_file() function when empy value
followed by no newline). (Felipe)
- Fixed bug #51844 (checkdnsrr does not support types other than MX). (Pierre)
- Fixed bug #51827 (Bad warning when register_shutdown_function called with
wrong num of parameters). (Felipe)
- Fixed bug #51822 (Segfault with strange __destruct() for static class
variables). (Dmitry)
- Fixed bug #51791 (constant() aborts execution when fail to check undefined
constant). (Felipe)
- Fixed bug #51732 (Fileinfo __construct or open does not work with NULL).
(Pierre)
- Fixed bug #51725 (xmlrpc_get_type() returns true on invalid dates). (Mike)
- Fixed bug #51723 (Content-length header is limited to 32bit integer with
Apache2 on Windows). (Pierre)
- Fixed bug #51721 (mark DOMNodeList and DOMNamedNodeMap as Traversable).
(David Zuelke)
- Fixed bug #51712 (Test mysql_mysqlnd_read_timeout_long must fail on MySQL4).
(Andrey)
- Fixed bug #51697 (Unsafe operations in free_storage of SPL iterators,
causes crash during shutdown). (Etienne)
- Fixed bug #51690 (Phar::setStub looks for case-sensitive
__HALT_COMPILER()). (Ilia)
- Fixed bug #51688 (ini per dir crashes when invalid document root are given).
(Pierre)
- Fixed bug #51671 (imagefill does not work correctly for small images).
(Pierre)
- Fixed bug #51670 (getColumnMeta causes segfault when re-executing query
after calling nextRowset). (Pierrick)
- Fixed bug #51647 Certificate file without private key (pk in another file)
doesn't work. (Andrey)
- Fixed bug #51629 (CURLOPT_FOLLOWLOCATION error message is misleading).
(Pierre)
- Fixed bug #51627 (script path not correctly evaluated).
(russell dot tempero at rightnow dot com)
- Fixed bug #51624 (Crash when calling mysqli_options()). (Felipe)
- Fixed bug #51615 (PHP crash with wrong HTML in SimpleXML). (Felipe)
- Fixed bug #51609 (pg_copy_to: Invalid results when using fourth parameter).
(Felipe)
- Fixed bug #51608 (pg_copy_to: WARNING: nonstandard use of \\ in a string
literal). (cbandy at jbandy dot com)
- Fixed bug #51607 (pg_copy_from does not allow schema in the tablename
argument). (cbandy at jbandy dot com)
- Fixed bug #51605 (Mysqli - zombie links). (Andrey)
- Fixed bug #51604 (newline in end of header is shown in start of message).
(Daniel Egeberg)
- Fixed bug #51590 (JSON_ERROR_UTF8 is undefined). (Felipe)
- Fixed bug #51583 (Bus error due to wrong alignment in mysqlnd). (Rainer Jung)
- Fixed bug #51582 (Don't assume UINT64_C it's ever available).
(reidrac at usebox dot net, Pierre)
- Fixed bug #51577 (Uninitialized memory reference with oci_bind_array_by_name)
(Oracle Corp.)
- Fixed bug #51562 (query timeout in mssql can not be changed per query).
(ejsmont dot artur at gmail dot com)
- Fixed bug #51552 (debug_backtrace() causes segmentation fault and/or memory
issues). (Dmitry)
- Fixed bug #51445 (var_dump() invalid/slow *RECURSION* detection). (Felipe)
- Fixed bug #51435 (Missing ifdefs / logic bug in crypt code cause compile
errors). (Felipe)
- Fixed bug #51424 (crypt() function hangs after 3rd call). (Pierre, Sriram)
- Fixed bug #51394 (Error line reported incorrectly if error handler throws an
exception). (Stas)
- Fixed bug #51393 (DateTime::createFromFormat() fails if format string contains
timezone). (Adam)
- Fixed bug #51347 (mysqli_close / connection memory leak). (Andrey, Johannes)
- Fixed bug #51338 (URL-Rewriter is still enabled if use_only_cookies is
on). (Ilia, j dot jeising at gmail dot com)
- Fixed bug #51291 (oci_error doesn't report last error when called two times)
(Oracle Corp.)
- Fixed bug #51276 (php_load_extension() is missing when HAVE_LIBDL is
undefined). (Tony)
- Fixed bug #51273 (Faultstring property does not exist when the faultstring is
empty) (Ilia, dennis at transip dot nl)
- Fixed bug #51269 (zlib.output_compression Overwrites Vary Header). (Adam)
- Fixed bug #51257 (CURL_VERSION_LARGEFILE incorrectly used after libcurl
version 7.10.1). (aron dot ujvari at microsec dot hu)
@@ -21,39 +559,95 @@ PHP NEWS
alexr at oplot dot com)
- Fixed bug #51190 (ftp_put() returns false when transfer was successful).
(Ilia)
- Fixed bug #51183 (ext/date/php_date.c fails to compile with Sun Studio).
(Sriram Natarajan)
- Fixed bug #51176 (Static calling in non-static method behaves like $this->).
(Felipe)
- Fixed bug #51171 (curl_setopt() doesn't output any errors or warnings when
an invalid option is provided). (Ilia)
- Fixed bug #51128 (imagefill() doesn't work with large images). (Pierre)
- Fixed bug #51096 ('last day' and 'first day' are handled incorrectly when
parsing date strings). (Derick)
- Fixed bug #51086 (DBA DB4 doesn't work with Berkeley DB 4.8). (Chris Jones)
- Fixed bug #51062 (DBA DB4 uses mismatched headers and libraries). (Chris Jones)
- Fixed bug #51062 (DBA DB4 uses mismatched headers and libraries). (Chris
Jones)
- Fixed bug #51026 (mysqli_ssl_set not working). (Andrey)
- Fixed bug #51023 (filter doesn't detect int overflows with GCC 4.4).
(Raphael Geissert)
- Fixed bug #50999 (unaligned memory access in dba_fetch()). (Felipe)
- Fixed bug #50976 (Soap headers Authorization not allowed).
(Brain France, Dmitry)
- Fixed bug #50828 (DOMNotation is not subclass of DOMNode). (Rob)
- Fixed bug #50810 (property_exists does not work for private). (Felipe)
- Fixed bug #50762 (in WSDL mode Soap Header handler function only being called
if defined in WSDL). (mephius at gmail dot com)
- Fixed bug #50731 (Inconsistent namespaces sent to functions registered with
spl_autoload_register). (Felipe)
- Fixed bug #50555 (DateTime::sub() allows 'relative' time modifications). (Derick)
- Fixed bug #50563 (removing E_WARNING from parse_url). (ralph at smashlabs dot
com, Pierre)
- Fixed bug #50578 (incorrect shebang in phar.phar). (Fedora at FamilleCollet
dot com)
- Fixed bug #50392 (date_create_from_format enforces 6 digits for 'u' format
character). (Derick)
- Fixed bug #50383 (Exceptions thrown in __call / __callStatic do not include
file and line in trace). (Felipe)
- Fixed bug #50358 (Compile failure compiling ext/phar/util.lo). (Felipe)
- Fixed bug #50101 (name clash between global and local variable).
(patch by yoarvi at gmail dot com)
- Fixed bug #50055 (DateTime::sub() allows 'relative' time modifications).
(Derick)
- Fixed bug #51002 (fix possible memory corruption with very long names).
(Pierre)
- Fixed bug #49893 (Crash while creating an instance of Zend_Mail_Storage_Pop3).
(Dmitry)
- Fixed bug #49819 (STDOUT losing data with posix_isatty()). (Mike)
- Fixed bug #49778 (DateInterval::format("%a") is always zero when an interval
is created from an ISO string). (Derick)
- Fixed bug #49700 (memory leaks in php_date.c if garbage collector is
enabled). (Dmitry)
- Fixed bug #49576 (FILTER_VALIDATE_EMAIL filter needs updating) (Rasmus)
- Fixed bug #49490 (XPath namespace prefix conflict). (Rob)
- Fixed bug #49429 (odbc_autocommit doesn't work). (Felipe)
- Fixed bug #49320 (PDO returns null when SQLite connection fails). (Felipe)
- Fixed bug #49234 (mysqli_ssl_set not found). (Andrey)
- Fixed bug #49216 (Reflection doesn't seem to work properly on MySqli).
(Andrey)
- Fixed bug #49192 (PHP crashes when GC invoked on COM object). (Stas)
- Fixed bug #49081 (DateTime::diff() mistake if start in January and interval >
28 days). (Derick)
- Fixed bug #49059 (DateTime::diff() repeats previous sub() operation).
(yoarvi@gmail.com, Derick)
- Fixed bug #48983 (DomDocument : saveHTMLFile wrong charset). (Rob)
- Fixed bug #48930 (__COMPILER_HALT_OFFSET__ incorrect in PHP >= 5.3). (Felipe)
- Fixed bug #48902 (Timezone database fallback map is outdated). (Derick)
- Fixed bug #48781 (Cyclical garbage collector memory leak). (Dmitry)
- Fixed bug #48601 (xpath() returns FALSE for legitimate query). (Rob)
- Fixed bug #48361 (SplFileInfo::getPathInfo should return the
parent dir). (Etienne)
- Fixed bug #48289 (iconv_mime_encode() quoted-printable scheme is broken).
(Adam, patch from hiroaki dot kawai at gmail dot com).
- Fixed bug #47842 (sscanf() does not support 64-bit values). (Mike)
- Fixed bug #46111 (Some timezone identifiers can not be parsed). (Derick)
- Fixed bug #45808 (stream_socket_enable_crypto() blocks and eats CPU).
(vincent at optilian dot com)
- Fixed bug #43233 (sasl support for ldap on Windows). (Pierre)
- Fixed bug #35673 (formatOutput does not work with saveHTML). (Rob)
- Fixed bug #33210 (getimagesize() fails to detect width/height on certain
JPEGs). (Ilia)
04 Mar 2010, PHP 5.3.2
?? ??? 20??, PHP 5.3.2
- Upgraded bundled sqlite to version 3.6.22. (Ilia)
- Upgraded bundled libmagic to version 5.03. (Mikko)
- Upgraded bundled PCRE to version 8.00. (Scott)
- Updated timezone database to version 2010.3. (Derick)
- Improved LCG entropy. (Rasmus, Samy Kamkar)
- Improved crypt support for edge cases (UFC compatibility). (Solar Designer,
Joey, Pierre)
- Reverted fix for bug #49521 (PDO fetchObject sets values before calling
constructor). (Pierrick, Johannes)
- Changed gmp_strval() to use full range from 2 to 62, and -2 to -36. FR #50283
(David Soria Parra)
@@ -85,12 +679,8 @@ PHP NEWS
(Linus Nielsen Feltzing <linus@haxx.se>)
- Added client-side server name indication support in openssl. (Arnaud)
- Improved crypt support for edge cases (UFC compatibility). (Solar Designer,
Joey, Pierre)
- Improved fix for bug #50006 (Segfault caused by uksort()). (Stas)
- Fixed crypt's blowfish sanity check of the "setting" string, to reject iteration
counts encoded as 36 through 39. (Solar Designer, Joey, Pierre)
- Fixed mysqlnd hang when queries exactly 16777214 bytes long are sent. (Andrey)
- Fixed incorrect decoding of 5-byte BIT sequences in mysqlnd. (Andrey)
- Fixed error_log() to be binary safe when using message_type 3. (Jani)
@@ -111,6 +701,8 @@ PHP NEWS
- Fixed memory leaks in the ACL function on Windows. (Pierre)
- Fixed memory leak in the realpath cache on Windows. (Pierre)
- Fixed memory leak in zip_close. (Pierre)
- Fixed crypt's blowfish sanity check of the "setting" string, to reject
iteration counts encoded as 36 through 39. (Solar Designer, Joey, Pierre)
- Fixed bug #51059 (crypt crashes when invalid salt are given). (Pierre)
- Fixed bug #50952 (allow underscore _ in constants parsed in php.ini files).
@@ -149,25 +741,6 @@ PHP NEWS
- Fixed bug #50632 (filter_input() does not return default value if the
variable does not exist). (Ilia)
- Fixed bug #50576 (XML_OPTION_SKIP_TAGSTART option has no effect). (Pierrick)
- Fixed bug #50416 (PROCEDURE db.myproc can't return a result set in the given
context). (Andrey)
- Fixed bug #49600 (imageTTFText text shifted right). (Takeshi Abe)
- Fixed bug #49585 (date_format buffer not long enough for >4 digit years).
(Derick, Adam)
- Fixed bug #49560 (oci8: using LOBs causes slow PHP shutdown). (Oracle Corp.)
- Fixed bug #49463 (setAttributeNS fails setting default namespace). (Rob)
- Fixed bug #48811 (Directives in PATH section do not get applied to
subdirectories). (Patch by: ct at swin dot edu dot au)
- Fixed bug #48590 (SoapClient does not honor max_redirects). (Sriram)
- Fixed bug #48190 (Content-type parameter "boundary" is not case-insensitive
in HTTP uploads). (Ilia)
- Fixed bug #47409 (extract() problem with array containing word "this").
(Ilia, chrisstocktonaz at gmail dot com)
- Fixed bug #47281 ($php_errormsg is limited in size of characters)
(Oracle Corp.)
- Fixed bug #44827 (define() allows :: in constant names). (Ilia)
- Fixed bug #44098 (imap_utf8() returns only capital letters).
(steffen at dislabs dot de, Pierre)
- Fixed bug #50558 (Broken object model when extending tidy). (Pierrick)
- Fixed bug #50540 (Crash while running ldap_next_reference test cases).
(Sriram)
@@ -182,6 +755,8 @@ PHP NEWS
- Fixed bug #50458 (PDO::FETCH_FUNC fails with Closures). (Felipe, Pierrick)
- Fixed bug #50445 (PDO-ODBC stored procedure call from Solaris 64-bit causes
seg fault). (davbrown4 at yahoo dot com, Felipe)
- Fixed bug #50416 (PROCEDURE db.myproc can't return a result set in the given
context). (Andrey)
- Fixed bug #50394 (Reference argument converted to value in __call). (Stas)
- Fixed bug #50351 (performance regression handling objects, ten times slower
in 5.3 than in 5.2). (Dmitry)
@@ -262,26 +837,41 @@ PHP NEWS
- Fixed bug #49660 (libxml 2.7.3+ limits text nodes to 10MB). (Felipe)
- Fixed bug #49647 (DOMUserData does not exist). (Rob)
- Fixed bug #49600 (imageTTFText text shifted right). (Takeshi Abe)
- Fixed bug #49585 (date_format buffer not long enough for >4 digit years).
(Derick, Adam)
- Fixed bug #49560 (oci8: using LOBs causes slow PHP shutdown). (Oracle Corp.)
- Fixed bug #49521 (PDO fetchObject sets values before calling constructor).
(Pierrick)
- Fixed bug #49472 (Constants defined in Interfaces can be overridden).
(Felipe)
- Fixed bug #49463 (setAttributeNS fails setting default namespace). (Rob)
- Fixed bug #49244 (Floating point NaN cause garbage characters). (Sjoerd)
- Fixed bug #49224 (Compile error due to old DNS functions on AIX systems).
(Scott)
- Fixed bug #49174 (crash when extending PDOStatement and trying to set
queryString property). (Felipe)
- Fixed bug #48811 (Directives in PATH section do not get applied to
subdirectories). (Patch by: ct at swin dot edu dot au)
- Fixed bug #48590 (SoapClient does not honor max_redirects). (Sriram)
- Fixed bug #48190 (Content-type parameter "boundary" is not case-insensitive
in HTTP uploads). (Ilia)
- Fixed bug #47848 (importNode doesn't preserve attribute namespaces). (Rob)
- Fixed bug #47409 (extract() problem with array containing word "this").
(Ilia, chrisstocktonaz at gmail dot com)
- Fixed bug #47281 ($php_errormsg is limited in size of characters)
(Oracle Corp.)
- Fixed bug #46478 (htmlentities() uses obsolete mapping table for character
entity references). (Moriyoshi)
- Fixed bug #45599 (strip_tags() truncates rest of string with invalid
attribute). (Ilia, hradtke)
- Fixed bug #45120 (PDOStatement->execute() returns true then false for same
statement). (Pierrick)
- Fixed bug #44827 (define() allows :: in constant names). (Ilia)
- Fixed bug #44098 (imap_utf8() returns only capital letters).
(steffen at dislabs dot de, Pierre)
- Fixed bug #34852 (Failure in odbc_exec() using oracle-supplied odbc
driver). (tim dot tassonis at trivadis dot com)
19 Nov 2009, PHP 5.3.1
- Upgraded bundled sqlite to version 3.6.19. (Scott)
- Updated timezone database to version 2009.17 (2009q). (Derick)
-57
View File
@@ -1,57 +0,0 @@
QNX4 Installation Notes
-----------------------
NOTE: General installation instructions are in the INSTALL file
1. To compile and test PHP3 you have to grab, compile and install:
- GNU dbm library or another db library;
- GNU bison (1.25 or later; 1.25 tested);
- GNU flex (any version supporting -o and -P options; 2.5.4 tested);
- GNU diffutils (any version supporting -w option; 2.7 tested);
2. To use CVS version you may need also:
- GNU CVS (1.9 tested);
- GNU autoconf (2.12 tested);
- GNU m4 (1.3 or later preferable; 1.4 tested);
3. To run configure define -lunix in command line:
LDFLAGS=-lunix ./configure
4. To use Sybase SQL Anywhere define ODBC_QNX and CUSTOM_ODBC_LIBS in
command line and run configure with --with-custom-odbc:
CFLAGS=-DODBC_QNX LDFLAGS=-lunix CUSTOM_ODBC_LIBS="-ldblib -lodbc" ./configure --with-custom-odbc=/usr/lib/sqlany50
If you have SQL Anywhere version 5.5.00, then you have to add
CFLAGS=-DSQLANY_BUG
to workaround its SQLFreeEnv() bug. Other versions has not been tested,
so try without this flag first.
5. To build the Apache module, you may have to hardcode an include path for
alloc.h in your Apache base directory:
- APACHE_DIRECTORY/src/httpd.h:
change #include "alloc.h"
to #include "APACHE_DIRECTORY/src/alloc.h"
Unless you want to use system regex library, you have to hardcode also
a path to regex.h:
- APACHE_DIRECTORY/src/conf.h:
change #include <regex.h>
to #include "APACHE_DIRECTORY/src/regex/regex.h"
I don't know so far why this required for QNX, may be it is Watcom
compiler problem.
If you building Apache module with SQL Anywhere support, you'll get
symbol conflict with BOOL. It is defined in Apache (httpd.h) and in
SQL Anywhere (odbc.h). This has nothing to do with PHP, so you have to
fix it yourself someway.
6. With above precautions, it should compile as is and pass regression
tests completely:
make
make check
make install
Don't bother me unless you really sure you made that all but it
still doesn't work.
June 28, 1998
Igor Kovalenko -- owl@infomarket.ru
+125 -95
View File
@@ -1,74 +1,134 @@
Submitting Patches to PHP
=========================
Submitting Enhancements and Patches to PHP
==========================================
This document describes how to submit a patch for PHP. Creating a
patch for PHP is easy!
This document describes how to submit an enhancement or patch for PHP.
It's easy!
You don't need any login accounts or special access to download,
build, debug and begin submitting PHP code, tests or documentation for
inclusion in PHP. Once you've followed this README and had several
patches accepted, PHP commit privileges are often quickly granted.
build, debug and begin submitting PHP, PECL or PEAR code, tests or
documentation. Once you've followed this README and had several
patches accepted, commit privileges are often quickly granted.
An excellent article to read first is:
http://phpadvent.org/2008/less-whining-more-coding-by-elizabeth-smith
Prework
-------
If you are fixing broken functionality then create a bug or identify
an existing bug at http://bugs.php.net/. This can be used to track
the patch progress and prevent your changes getting lost in the PHP
mail archives.
Online Forums
-------------
There are several IRC channels where PHP developers are often
available to discuss questions. They include #php.pecl, #php.doc and
#pear on the EFNet network and #php-dev-win on FreeNode.
If your code change is large, then first discuss it with the extension
maintainer and/or a development mail list. Extension maintainers can
be found in the EXTENSIONS file in the PHP source. Use the
internals@lists.php.net mail list to discuss changes to the base PHP
code. Use pecl-dev@lists.php.net for changes to code that is only
available from PECL (http://pecl.php.net/). Use pear-dev@lists.php.net
for PEAR modules (http://pear.php.net/). Use phpdoc@lists.php.net for
PHP documentation questions. Mail list subscription is explained on
http://www.php.net/mailing-lists.php.
If a PHP or PECL patch affects user functionality or makes significant
internal changes then create a simple Request For Comment (RFC) page
on http://wiki.php.net/rfc before starting discussion. This RFC can be
used for initial discussion and later for documentation. Wiki accounts
can be requested on http://wiki.php.net/start?do=register
PHP Patches
-----------
If you are fixing broken functionality in PHP C source code first
create a bug or identify an existing bug at http://bugs.php.net/. A
bug can be used to track the patch progress and prevent your changes
getting lost in the PHP mail archives.
Online information on PHP internal C functions is at
http://www.php.net/internals, though this is considered
incomplete. Various external resources can be found on the web. A
standard reference is the book "Extending and Embedding PHP" by Sara
If your change is large then create a Request For Comment (RFC) page
on http://wiki.php.net/rfc, discuss it with the extension maintainer,
and discuss it on the development mail list internals@lists.php.net.
RFC Wiki accounts can be requested on
http://wiki.php.net/start?do=register. PHP extension maintainers can
be found in the EXTENSIONS file in the PHP source. Mail list
subscription is explained on http://www.php.net/mailing-lists.php.
Information on PHP internal C functions is at
http://www.php.net/internals, though this is considered incomplete.
Various external resources can be found on the web. A standard
printed reference is the book "Extending and Embedding PHP" by Sara
Golemon.
Information on contributing to PEAR is available at
http://pear.php.net/manual/en/guide-developers.php
Attach the patch to the PHP bug and consider sending a notification
email about the change to internals@lists.php.net. Also CC the
extension maintainer. Explain what has been changed by your patch.
Test scripts should be included.
Please make the mail subject prefix "[PATCH]". If attaching a patch,
ensure it has a file extension of ".txt". This is because only MIME
attachments of type 'text/*' are accepted.
PHP Documentation Patches
-------------------------
If you are fixing incorrect PHP documentation first create a bug or
identify an existing bug at http://bugs.php.net/. A bug can be used
to track the patch progress and prevent your changes getting lost in
the PHP mail archives.
If your change is large, then first discuss it with the mail list
phpdoc@lists.php.net. Subscription is explained on
http://www.php.net/mailing-lists.php.
Information on contributing to PHP documentation is at
http://php.net/dochowto and http://wiki.php.net/doc/howto
There are several IRC channels where PHP developers are often
available to discuss questions. They include #php.pecl and #php.doc
on the EFNet network and #php-dev-win on FreeNode.
Attach the patch to the PHP bug and consider sending a notification
email about the change to phpdoc@lists.php.net. Explain what has been
fixed/added/changed by your patch.
Please make the mail subject prefix "[PATCH]". Include the bug id(s)
which can be closed by your patch. If attaching a patch, ensure it
has a file extension of ".txt". This is because only MIME attachments
of type 'text/*' are accepted.
How to create your patch
------------------------
PHP uses Subversion (SVN) for revision control. Read
PECL Extension Patches: http://pecl.php.net/
--------------------------------------------
If you are fixing broken functionality in a PECL extension then create
a bug or identify an existing bug at http://pecl.php.net/bugs/. A bug
can be used to track the patch progress and prevent your changes
getting lost in the PHP mail archives.
If your change is large then create a Request For Comment (RFC) page
on http://wiki.php.net/rfc, discuss it with the extension maintainer,
and discuss it on the development mail list pecl-dev@lists.php.net.
PECL mail list subscription is explained on
http://pecl.php.net/support.php. RFC Wiki accounts can be requested
on http://wiki.php.net/start?do=register
Information on PHP internal C functions is at
http://www.php.net/internals, though this is considered incomplete.
Various external resources can be found on the web. A standard
printed reference is the book "Extending and Embedding PHP" by Sara
Golemon.
Update any open bugs and add a link to the source of your patch. Send
the patch or pointer to the bug to pecl-dev@lists.php.net. Also CC
the extension maintainer. Explain what has been changed by your
patch. Test scripts should be included.
Please make the mail subject prefix "[PATCH] ...". Include the patch
as an attachment with a file extension of ".txt". This is because
only MIME attachments of type 'text/*' are accepted.
PEAR Package Patches: http://pear.php.net/
------------------------------------------
Information on contributing to PEAR is available at
http://pear.php.net/manual/en/developers-newmaint.php and
http://pear.php.net/manual/en/guide-developers.php
How to create your PHP, PHP Documentation or PECL patch
-------------------------------------------------------
PHP and PECL use Subversion (SVN) for revision control. Read
http://www.php.net/svn.php for help on using SVN to get and build PHP
source code. We recommend using a Sparse Directory checkout described
in http://wiki.php.net/vcs/svnfaq. If you are new to SVN, read
source code. We recommend using a Sparse Directory checkout described
in http://wiki.php.net/vcs/svnfaq. If you are new to SVN, read
http://svnbook.red-bean.com.
Generally we ask that patches work on the current stable PHP
development branch and on "trunk".
Generally we ask that bug fix patches work on the current stable PHP
development branches and on "trunk". New PHP features only need to
work on "trunk".
Read CODING_STANDARDS before you start working.
After modifying the source see README.TESTING and
http://qa.php.net/write-test.php for how to test. Submitting test
scripts helps us to understand what functionality has changed. It is
http://qa.php.net/write-test.php for how to test. Submitting test
scripts helps us to understand what functionality has changed. It is
important for the stability and maintainability of PHP that tests are
comprehensive.
@@ -80,73 +140,43 @@ For ease of review and later troubleshooting, submit individual
patches for each bug or feature.
Checklist for submitting your patch
-----------------------------------
Checklist for submitting your PHP or PECL code patch
----------------------------------------------------
- Update SVN source just before running your final 'diff' and
before testing.
- Add in-line comments and/or have external documentation ready.
Use only "/* */" style comments, not "//".
- Create test scripts for use with "make test".
- Run "make test" to check your patch doesn't break other features.
- Rebuild PHP with --enable-debug (which will show some kinds of
memory errors) and check the PHP and web server error logs after
running the PHP tests.
- Rebuild PHP with --enable-maintainer-zts to check your patch compiles
on multi-threaded web servers.
- Create test scripts for use with "make test".
- Add in-line comments and/or have external documentation ready.
running your PHP tests.
- Rebuild PHP with --enable-maintainer-zts to check your patch
compiles on multi-threaded web servers.
- Review the patch once more just before submitting it.
Where to send your patch
------------------------
If you are patching PHP C source then email the patch to
internals@lists.php.net
If you patching a PECL extension then send the patch to
pecl-dev@lists.php.net
If you are patching PEAR then send the patch to
pear-dev@lists.php.net
If you are patching PHP's documentation then send the patch to
phpdoc@lists.php.net
The mail can be CC'd to the extension maintainer (see EXTENSIONS).
Please make the subject prefix "[PATCH]", for example "[PATCH] Fix
return value of all array functions"
Include the patch as an attachment with a file extension of ".txt".
This is because only MIME attachments of type 'text/*' are accepted.
Explain what has been fixed/added/changed by your patch. Test scripts
should be included in the email.
Include the bug id(s) which can be closed by your patch.
Finally, update any open bugs and add a link to the source of your
patch.
What happens after you submit your patch
----------------------------------------
What happens after submitting your PHP, PHP Documentation or PECL patch
-----------------------------------------------------------------------
If your patch is easy to review and obviously has no side-effects,
it might be committed relatively quickly.
Because PHP is a volunteer-driven effort more complex patches will
require patience on your side. If you do not receive feedback in a few
days, consider resubmitting the patch. Before doing this think about
these questions:
require patience on your side. If you do not receive feedback in a
few days, consider resubmitting the patch. Before doing this think
about these questions:
- Did I send the patch to the right mail list?
- Did I review the mail list archives to see if these kind of
changes had been discussed before?
- Did I explain my patch clearly?
- Is my patch too hard to review? Because of which factors?
- Are there any unwanted white space changes?
- Is my patch too hard to review? Because of what factors?
What happens when your patch is applied
---------------------------------------
Your name will be included in the SVN commit log. If your patch
affects end users, a brief description and your name might be added to
the NEWS file.
What happens when your PHP or PECL patch is applied
---------------------------------------------------
Your name will likely be included in the SVN commit log. If your
patch affects end users, a brief description and your name might be
added to the NEWS file.
Thank you for patching PHP!
-5
View File
@@ -1,10 +1,5 @@
// vim:ft=javascript
// $Id$
if (CHECK_HEADER_ADD_INCLUDE("NewAPIs.h", "CFLAGS_PHP", php_usual_include_suspects)) {
// Need to add the flag directly, since TSRM doesn't include the config
// header
ADD_FLAG("CFLAGS_PHP", "/DHAVE_NEWAPIS_H=1");
}
ADD_SOURCES("TSRM", "TSRM.c tsrm_strtok_r.c tsrm_virtual_cwd.c tsrm_win32.c");
+221 -94
View File
@@ -14,6 +14,7 @@
+----------------------------------------------------------------------+
| Authors: Andi Gutmans <andi@zend.com> |
| Sascha Schumann <sascha@schumann.cx> |
| Pierre Joye <pierre@php.net> |
+----------------------------------------------------------------------+
*/
@@ -38,6 +39,18 @@
# ifndef IO_REPARSE_TAG_SYMLINK
# define IO_REPARSE_TAG_SYMLINK 0xA000000C
# endif
# ifndef VOLUME_NAME_NT
# define VOLUME_NAME_NT 0x2
# endif
# ifndef VOLUME_NAME_DOS
# define VOLUME_NAME_DOS 0x0
# endif
#endif
#ifndef S_IFLNK
# define S_IFLNK 0120000
#endif
#ifdef NETWARE
@@ -83,14 +96,14 @@ cwd_state main_cwd_state; /* True global */
#include <tchar.h>
#define tsrm_strtok_r(a,b,c) _tcstok((a),(b))
#define TOKENIZER_STRING "/\\"
static int php_check_dots(const char *element, int n)
static int php_check_dots(const char *element, int n)
{
while (n-- > 0) if (element[n] != '.') break;
return (n != -1);
}
#define IS_DIRECTORY_UP(element, len) \
(len >= 2 && !php_check_dots(element, len))
@@ -124,7 +137,7 @@ static int php_check_dots(const char *element, int n)
/* define this to check semantics */
#define IS_DIR_OK(s) (1)
#ifndef IS_DIR_OK
#define IS_DIR_OK(state) (php_is_dir_ok(state) == 0)
#endif
@@ -137,7 +150,7 @@ static int php_check_dots(const char *element, int n)
#define CWD_STATE_FREE(s) \
free((s)->cwd);
#ifdef TSRM_WIN32
#ifdef CTL_CODE
@@ -202,21 +215,98 @@ static inline time_t FileTimeToUnixTime(const FILETIME FileTime)
return (time_t)UnixTime;
}
CWD_API int php_sys_readlink(const char *link, char *target, size_t target_len){ /* {{{ */
HINSTANCE kernel32;
HANDLE hFile;
DWORD dwRet;
typedef BOOL (WINAPI *gfpnh_func)(HANDLE, LPTSTR, DWORD, DWORD);
gfpnh_func pGetFinalPathNameByHandle;
kernel32 = LoadLibrary("kernel32.dll");
if (kernel32) {
pGetFinalPathNameByHandle = (gfpnh_func)GetProcAddress(kernel32, "GetFinalPathNameByHandleA");
if (pGetFinalPathNameByHandle == NULL) {
return -1;
}
} else {
return -1;
}
hFile = CreateFile(link, // file to open
GENERIC_READ, // open for reading
FILE_SHARE_READ, // share for reading
NULL, // default security
OPEN_EXISTING, // existing file only
FILE_FLAG_BACKUP_SEMANTICS, // normal file
NULL); // no attr. template
if( hFile == INVALID_HANDLE_VALUE) {
return -1;
}
dwRet = pGetFinalPathNameByHandle(hFile, target, MAXPATHLEN, VOLUME_NAME_DOS);
if(dwRet >= MAXPATHLEN) {
return -1;
}
CloseHandle(hFile);
if(dwRet > 4) {
/* Skip first 4 characters if they are "\??\" */
if(target[0] == '\\' && target[1] == '\\' && target[2] == '?' && target[3] == '\\') {
char tmp[MAXPATHLEN];
unsigned int offset = 4;
dwRet -= 4;
/* \??\UNC\ */
if (dwRet > 7 && target[4] == 'U' && target[5] == 'N' && target[6] == 'C') {
offset += 2;
dwRet -= 2;
target[offset] = '\\';
}
memcpy(tmp, target + offset, dwRet);
memcpy(target, tmp, dwRet);
}
}
target[dwRet] = '\0';
return dwRet;
}
/* }}} */
CWD_API int php_sys_stat(const char *path, struct stat *buf) /* {{{ */
{
return php_sys_stat_ex(path, buf, 0);
}
/* }}} */
CWD_API int php_sys_lstat(const char *path, struct stat *buf) /* {{{ */
{
return php_sys_stat_ex(path, buf, 1);
}
/* }}} */
CWD_API int php_sys_stat_ex(const char *path, struct stat *buf, int lstat) /* {{{ */
{
WIN32_FILE_ATTRIBUTE_DATA data;
__int64 t;
const size_t path_len = strlen(path);
if (!GetFileAttributesEx(path, GetFileExInfoStandard, &data)) {
return stat(path, buf);
}
if (path[1] == ':') {
if (path_len >= 1 && path[1] == ':') {
if (path[0] >= 'A' && path[0] <= 'Z') {
buf->st_dev = buf->st_rdev = path[0] - 'A';
} else {
buf->st_dev = buf->st_rdev = path[0] - 'a';
}
} else if (IS_UNC_PATH(path, path_len)) {
buf->st_dev = buf->st_rdev = 0;
} else {
char cur_path[MAXPATHLEN+1];
DWORD len = sizeof(cur_path);
@@ -245,19 +335,56 @@ CWD_API int php_sys_stat(const char *path, struct stat *buf) /* {{{ */
}
if (tmp != cur_path) {
free(tmp);
}
}
}
buf->st_uid = buf->st_gid = buf->st_ino = 0;
buf->st_mode = (data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ? (S_IFDIR|S_IEXEC|(S_IEXEC>>3)|(S_IEXEC>>6)) : S_IFREG;
buf->st_mode |= (data.dwFileAttributes & FILE_ATTRIBUTE_READONLY) ? (S_IREAD|(S_IREAD>>3)|(S_IREAD>>6)) : (S_IREAD|(S_IREAD>>3)|(S_IREAD>>6)|S_IWRITE|(S_IWRITE>>3)|(S_IWRITE>>6));
if (lstat && data.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT) {
/* File is a reparse point. Get the target */
HANDLE hLink = NULL;
REPARSE_DATA_BUFFER * pbuffer;
unsigned int retlength = 0;
TSRM_ALLOCA_FLAG(use_heap_large);
hLink = CreateFile(path, GENERIC_READ, 0, NULL, OPEN_EXISTING, FILE_FLAG_OPEN_REPARSE_POINT|FILE_FLAG_BACKUP_SEMANTICS, NULL);
if(hLink == INVALID_HANDLE_VALUE) {
return -1;
}
pbuffer = (REPARSE_DATA_BUFFER *)tsrm_do_alloca(MAXIMUM_REPARSE_DATA_BUFFER_SIZE, use_heap_large);
if(!DeviceIoControl(hLink, FSCTL_GET_REPARSE_POINT, NULL, 0, pbuffer, MAXIMUM_REPARSE_DATA_BUFFER_SIZE, &retlength, NULL)) {
tsrm_free_alloca(pbuffer, use_heap_large);
CloseHandle(hLink);
return -1;
}
CloseHandle(hLink);
if(pbuffer->ReparseTag == IO_REPARSE_TAG_SYMLINK) {
buf->st_mode = S_IFLNK;
buf->st_mode |= (data.dwFileAttributes & FILE_ATTRIBUTE_READONLY) ? (S_IREAD|(S_IREAD>>3)|(S_IREAD>>6)) : (S_IREAD|(S_IREAD>>3)|(S_IREAD>>6)|S_IWRITE|(S_IWRITE>>3)|(S_IWRITE>>6));
}
#if 0 /* Not used yet */
else if(pbuffer->ReparseTag == IO_REPARSE_TAG_MOUNT_POINT) {
buf->st_mode |=;
}
#endif
tsrm_free_alloca(pbuffer, use_heap_large);
} else {
buf->st_mode = (data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ? (S_IFDIR|S_IEXEC|(S_IEXEC>>3)|(S_IEXEC>>6)) : S_IFREG;
buf->st_mode |= (data.dwFileAttributes & FILE_ATTRIBUTE_READONLY) ? (S_IREAD|(S_IREAD>>3)|(S_IREAD>>6)) : (S_IREAD|(S_IREAD>>3)|(S_IREAD>>6)|S_IWRITE|(S_IWRITE>>3)|(S_IWRITE>>6));
}
if ((data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) == 0) {
int len = strlen(path);
if (path[len-4] == '.') {
if (_memicmp(path+len-3, "exe", 3) == 0 ||
_memicmp(path+len-3, "com", 3) == 0 ||
_memicmp(path+len-3, "bat", 3) == 0 ||
_memicmp(path+len-3, "cmd", 3) == 0) {
_memicmp(path+len-3, "com", 3) == 0 ||
_memicmp(path+len-3, "bat", 3) == 0 ||
_memicmp(path+len-3, "cmd", 3) == 0) {
buf->st_mode |= (S_IEXEC|(S_IEXEC>>3)|(S_IEXEC>>6));
}
}
@@ -298,19 +425,19 @@ static int php_is_file_ok(const cwd_state *state) /* {{{ */
}
/* }}} */
static void cwd_globals_ctor(virtual_cwd_globals *cwd_globals TSRMLS_DC) /* {{{ */
static void cwd_globals_ctor(virtual_cwd_globals *cwd_g TSRMLS_DC) /* {{{ */
{
CWD_STATE_COPY(&cwd_globals->cwd, &main_cwd_state);
cwd_globals->realpath_cache_size = 0;
cwd_globals->realpath_cache_size_limit = REALPATH_CACHE_SIZE;
cwd_globals->realpath_cache_ttl = REALPATH_CACHE_TTL;
memset(cwd_globals->realpath_cache, 0, sizeof(cwd_globals->realpath_cache));
CWD_STATE_COPY(&cwd_g->cwd, &main_cwd_state);
cwd_g->realpath_cache_size = 0;
cwd_g->realpath_cache_size_limit = REALPATH_CACHE_SIZE;
cwd_g->realpath_cache_ttl = REALPATH_CACHE_TTL;
memset(cwd_g->realpath_cache, 0, sizeof(cwd_g->realpath_cache));
}
/* }}} */
static void cwd_globals_dtor(virtual_cwd_globals *cwd_globals TSRMLS_DC) /* {{{ */
static void cwd_globals_dtor(virtual_cwd_globals *cwd_g TSRMLS_DC) /* {{{ */
{
CWD_STATE_FREE(&cwd_globals->cwd);
CWD_STATE_FREE(&cwd_g->cwd);
realpath_cache_clean(TSRMLS_C);
}
/* }}} */
@@ -332,7 +459,7 @@ CWD_API void virtual_cwd_startup(void) /* {{{ */
}
}
#else
result = getcwd(cwd, sizeof(cwd));
result = getcwd(cwd, sizeof(cwd));
#endif
if (!result) {
cwd[0] = '\0';
@@ -383,7 +510,7 @@ CWD_API char *virtual_getcwd_ex(size_t *length TSRMLS_DC) /* {{{ */
*length = 1;
retval = (char *) malloc(2);
retval[0] = DEFAULT_SLASH;
retval[1] = '\0';
retval[1] = '\0';
return retval;
}
@@ -493,7 +620,7 @@ CWD_API void realpath_cache_del(const char *path, int path_len TSRMLS_DC) /* {{{
while (*bucket != NULL) {
if (key == (*bucket)->key && path_len == (*bucket)->path_len &&
memcmp(path, (*bucket)->path, path_len) == 0) {
memcmp(path, (*bucket)->path, path_len) == 0) {
realpath_cache_bucket *r = *bucket;
*bucket = (*bucket)->next;
CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1;
@@ -510,9 +637,9 @@ static inline void realpath_cache_add(const char *path, int path_len, const char
{
long size = sizeof(realpath_cache_bucket) + path_len + 1;
int same = 1;
if (realpath_len != path_len ||
memcmp(path, realpath, path_len) != 0) {
memcmp(path, realpath, path_len) != 0) {
size += realpath_len + 1;
same = 0;
}
@@ -570,7 +697,7 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p
CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1;
free(r);
} else if (key == (*bucket)->key && path_len == (*bucket)->path_len &&
memcmp(path, (*bucket)->path, path_len) == 0) {
memcmp(path, (*bucket)->path, path_len) == 0) {
return *bucket;
} else {
bucket = &(*bucket)->next;
@@ -582,21 +709,21 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p
CWD_API realpath_cache_bucket* realpath_cache_lookup(const char *path, int path_len, time_t t TSRMLS_DC) /* {{{ */
{
return realpath_cache_find(path, path_len, t TSRMLS_CC);
return realpath_cache_find(path, path_len, t TSRMLS_CC);
}
/* }}} */
CWD_API int realpath_cache_size(TSRMLS_D)
CWD_API int realpath_cache_size(TSRMLS_D)
{
return CWDG(realpath_cache_size);
}
CWD_API int realpath_cache_max_buckets(TSRMLS_D)
CWD_API int realpath_cache_max_buckets(TSRMLS_D)
{
return (sizeof(CWDG(realpath_cache)) / sizeof(CWDG(realpath_cache)[0]));
}
CWD_API realpath_cache_bucket** realpath_cache_get_buckets(TSRMLS_D)
CWD_API realpath_cache_bucket** realpath_cache_get_buckets(TSRMLS_D)
{
return CWDG(realpath_cache);
}
@@ -650,14 +777,14 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
if (!start) {
/* leading '..' must not be removed in case of relative path */
if (j == 0 && path[0] == '.' && path[1] == '.' &&
IS_SLASH(path[2])) {
IS_SLASH(path[2])) {
path[3] = '.';
path[4] = '.';
path[5] = DEFAULT_SLASH;
j = 5;
} else if (j > 0 &&
path[j+1] == '.' && path[j+2] == '.' &&
IS_SLASH(path[j+3])) {
} else if (j > 0 &&
path[j+1] == '.' && path[j+2] == '.' &&
IS_SLASH(path[j+3])) {
j += 4;
path[j++] = '.';
path[j++] = '.';
@@ -673,7 +800,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
}
return j;
}
path[len] = 0;
save = (use_realpath != CWD_EXPAND);
@@ -683,18 +810,18 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
if (!*t) {
*t = time(0);
}
if ((bucket = realpath_cache_find(path, len, *t TSRMLS_CC)) != NULL) {
if (is_dir && !bucket->is_dir) {
if ((bucket = realpath_cache_find(path, len, *t TSRMLS_CC)) != NULL) {
if (is_dir && !bucket->is_dir) {
/* not a directory */
return -1;
} else {
if (link_is_dir) {
*link_is_dir = bucket->is_dir;
}
} else {
if (link_is_dir) {
*link_is_dir = bucket->is_dir;
}
memcpy(path, bucket->realpath, bucket->realpath_len + 1);
return bucket->realpath_len;
return bucket->realpath_len;
}
}
}
}
#ifdef TSRM_WIN32
@@ -706,7 +833,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
/* continue resolution anyway but don't save result in the cache */
save = 0;
}
if (save) {
FindClose(hFind);
}
@@ -714,9 +841,9 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
tmp = tsrm_do_alloca(len+1, use_heap);
memcpy(tmp, path, len+1);
if(save &&
!(IS_UNC_PATH(path, len) && len >= 3 && path[2] != '?') &&
(data.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT)) {
if(save &&
!(IS_UNC_PATH(path, len) && len >= 3 && path[2] != '?') &&
(data.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT)) {
/* File is a reparse point. Get the target */
HANDLE hLink = NULL;
REPARSE_DATA_BUFFER * pbuffer;
@@ -751,7 +878,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
reparsetarget = pbuffer->SymbolicLinkReparseBuffer.ReparseTarget;
printname_len = pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR);
isabsolute = (pbuffer->SymbolicLinkReparseBuffer.Flags == 0) ? 1 : 0;
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
reparsetarget + pbuffer->MountPointReparseBuffer.PrintNameOffset / sizeof(WCHAR),
printname_len + 1,
printname, MAX_PATH, NULL, NULL
@@ -763,7 +890,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
printname[printname_len] = 0;
substitutename_len = pbuffer->MountPointReparseBuffer.SubstituteNameLength / sizeof(WCHAR);
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
reparsetarget + pbuffer->MountPointReparseBuffer.SubstituteNameOffset / sizeof(WCHAR),
substitutename_len + 1,
substitutename, MAX_PATH, NULL, NULL
@@ -777,7 +904,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
isabsolute = 1;
reparsetarget = pbuffer->MountPointReparseBuffer.ReparseTarget;
printname_len = pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR);
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
reparsetarget + pbuffer->MountPointReparseBuffer.PrintNameOffset / sizeof(WCHAR),
printname_len + 1,
printname, MAX_PATH, NULL, NULL
@@ -788,7 +915,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
printname[pbuffer->MountPointReparseBuffer.PrintNameLength / sizeof(WCHAR)] = 0;
substitutename_len = pbuffer->MountPointReparseBuffer.SubstituteNameLength / sizeof(WCHAR);
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
if (!WideCharToMultiByte(CP_THREAD_ACP, 0,
reparsetarget + pbuffer->MountPointReparseBuffer.SubstituteNameOffset / sizeof(WCHAR),
substitutename_len + 1,
substitutename, MAX_PATH, NULL, NULL
@@ -803,20 +930,22 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
}
if(isabsolute && substitutename_len > 4) {
/* Do not resolve volumes (for now). A mounted point can
/* Do not resolve volumes (for now). A mounted point can
target a volume without a drive, it is not certain that
all IO functions we use in php and its deps support
all IO functions we use in php and its deps support
path with volume GUID instead of the DOS way, like:
d:\test\mnt\foo
\\?\Volume{62d1c3f8-83b9-11de-b108-806e6f6e6963}\foo
*/
if (strncmp(substitutename, "\\??\\Volume{",11) == 0
|| strncmp(substitutename, "\\\\?\\Volume{",11) == 0) {
isVolume = TRUE;
if (strncmp(substitutename, "\\??\\Volume{",11) == 0
|| strncmp(substitutename, "\\\\?\\Volume{",11) == 0
|| strncmp(substitutename, "\\??\\UNC\\", 8) == 0
) {
isVolume = TRUE;
substitutename_off = 0;
} else
/* do not use the \??\ and \\?\ prefix*/
if (strncmp(substitutename, "\\??\\", 4) == 0
if (strncmp(substitutename, "\\??\\", 4) == 0
|| strncmp(substitutename, "\\\\?\\", 4) == 0) {
substitutename_off = 4;
}
@@ -887,7 +1016,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
tmp = tsrm_do_alloca(len+1, use_heap);
memcpy(tmp, path, len+1);
#else
if (save && lstat(path, &st) < 0) {
if (save && php_sys_lstat(path, &st) < 0) {
if (use_realpath == CWD_REALPATH) {
/* file not found */
return -1;
@@ -900,8 +1029,8 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
memcpy(tmp, path, len+1);
if (save && S_ISLNK(st.st_mode)) {
if (++(*ll) > LINK_MAX || (j = readlink(tmp, path, MAXPATHLEN)) < 0) {
/* too many links or broken symlinks */
if (++(*ll) > LINK_MAX || (j = php_sys_readlink(tmp, path, MAXPATHLEN)) < 0) {
/* too many links or broken symlinks */
tsrm_free_alloca(tmp, use_heap);
return -1;
}
@@ -913,10 +1042,10 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i
return -1;
}
} else {
if (i + j >= MAXPATHLEN-1) {
if (i + j >= MAXPATHLEN-1) {
tsrm_free_alloca(tmp, use_heap);
return -1; /* buffer overflow */
}
}
memmove(path+i, path, j+1);
memcpy(path, tmp, i-1);
path[i-1] = DEFAULT_SLASH;
@@ -1038,18 +1167,18 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
state_cwd_length = 2;
while (IS_SLASH(state->cwd[state_cwd_length])) {
state_cwd_length++;
}
}
while (state->cwd[state_cwd_length] &&
!IS_SLASH(state->cwd[state_cwd_length])) {
!IS_SLASH(state->cwd[state_cwd_length])) {
state_cwd_length++;
}
}
while (IS_SLASH(state->cwd[state_cwd_length])) {
state_cwd_length++;
}
}
while (state->cwd[state_cwd_length] &&
!IS_SLASH(state->cwd[state_cwd_length])) {
!IS_SLASH(state->cwd[state_cwd_length])) {
state_cwd_length++;
}
}
}
}
#endif
@@ -1061,7 +1190,7 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
memcpy(resolved_path + state_cwd_length + 1, path, path_length + 1);
path_length += state_cwd_length + 1;
}
} else {
} else {
#ifdef TSRM_WIN32
if (path_length > 2 && path[1] == ':' && !IS_SLASH(path[2])) {
resolved_path[0] = path[0];
@@ -1072,11 +1201,11 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
} else
#endif
memcpy(resolved_path, path, path_length + 1);
}
}
#ifdef TSRM_WIN32
if (memchr(resolved_path, '*', path_length) ||
memchr(resolved_path, '?', path_length)) {
memchr(resolved_path, '?', path_length)) {
return 1;
}
#endif
@@ -1126,12 +1255,12 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
add_slash = (use_realpath != CWD_REALPATH) && path_length > 0 && IS_SLASH(resolved_path[path_length-1]);
t = CWDG(realpath_cache_ttl) ? 0 : -1;
path_length = tsrm_realpath_r(resolved_path, start, path_length, &ll, &t, use_realpath, 0, NULL TSRMLS_CC);
if (path_length < 0) {
errno = ENOENT;
return 1;
}
if (!start && !path_length) {
resolved_path[path_length++] = '.';
}
@@ -1184,7 +1313,7 @@ verify:
memcpy(state->cwd, resolved_path, state->cwd_length+1);
ret = 0;
}
#if VIRTUAL_CWD_DEBUG
fprintf (stderr, "virtual_file_ex() = %s\n",state->cwd);
#endif
@@ -1207,7 +1336,7 @@ CWD_API int virtual_chdir_file(const char *path, int (*p_chdir)(const char *path
if (length == 0) {
return 1; /* Can't cd to empty string */
}
}
while(--length >= 0 && !IS_SLASH(path[length])) {
}
@@ -1242,16 +1371,16 @@ CWD_API char *virtual_realpath(const char *path, char *real_path TSRMLS_DC) /* {
if (!*path) {
new_state.cwd = (char*)malloc(1);
new_state.cwd[0] = '\0';
new_state.cwd_length = 0;
if (VCWD_GETCWD(cwd, MAXPATHLEN)) {
path = cwd;
new_state.cwd_length = 0;
if (VCWD_GETCWD(cwd, MAXPATHLEN)) {
path = cwd;
}
} else if (!IS_ABSOLUTE_PATH(path, strlen(path))) {
CWD_STATE_COPY(&new_state, &CWDG(cwd));
} else {
new_state.cwd = (char*)malloc(1);
new_state.cwd[0] = '\0';
new_state.cwd_length = 0;
new_state.cwd_length = 0;
}
if (virtual_file_ex(&new_state, path, NULL, CWD_REALPATH)==0) {
@@ -1317,7 +1446,7 @@ CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC) /* {{{ */
{
cwd_state new_state;
int ret;
CWD_STATE_COPY(&new_state, &CWDG(cwd));
if (virtual_file_ex(&new_state, pathname, NULL, CWD_REALPATH)) {
CWD_STATE_FREE(&new_state);
@@ -1329,9 +1458,9 @@ CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC) /* {{{ */
#else
ret = access(new_state.cwd, mode);
#endif
CWD_STATE_FREE(&new_state);
return ret;
}
/* }}} */
@@ -1352,12 +1481,12 @@ static void UnixTimeToFileTime(time_t t, LPFILETIME pft) /* {{{ */
TSRM_API int win32_utime(const char *filename, struct utimbuf *buf) /* {{{ */
{
FILETIME mtime, atime;
HANDLE hFile;
HANDLE hFile;
hFile = CreateFile(filename, GENERIC_WRITE, FILE_SHARE_WRITE|FILE_SHARE_READ, NULL,
OPEN_ALWAYS, FILE_FLAG_BACKUP_SEMANTICS, NULL);
/* OPEN_ALWAYS mode sets the last error to ERROR_ALREADY_EXISTS but
/* OPEN_ALWAYS mode sets the last error to ERROR_ALREADY_EXISTS but
the CreateFile operation succeeds */
if (GetLastError() == ERROR_ALREADY_EXISTS) {
SetLastError(0);
@@ -1477,7 +1606,7 @@ CWD_API int virtual_open(const char *path TSRMLS_DC, int flags, ...) /* {{{ */
f = open(new_state.cwd, flags, mode);
} else {
f = open(new_state.cwd, flags);
}
}
CWD_STATE_FREE(&new_state);
return f;
}
@@ -1556,7 +1685,6 @@ CWD_API int virtual_stat(const char *path, struct stat *buf TSRMLS_DC) /* {{{ */
}
/* }}} */
#if !defined(TSRM_WIN32)
CWD_API int virtual_lstat(const char *path, struct stat *buf TSRMLS_DC) /* {{{ */
{
cwd_state new_state;
@@ -1568,13 +1696,12 @@ CWD_API int virtual_lstat(const char *path, struct stat *buf TSRMLS_DC) /* {{{ *
return -1;
}
retval = lstat(new_state.cwd, buf);
retval = php_sys_lstat(new_state.cwd, buf);
CWD_STATE_FREE(&new_state);
return retval;
}
/* }}} */
#endif
CWD_API int virtual_unlink(const char *path TSRMLS_DC) /* {{{ */
{
@@ -1738,7 +1865,7 @@ CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC) /*
}
*ptr++ = '\'';
}
*ptr++ = ' ';
*ptr++ = ';';
*ptr++ = ' ';
@@ -1761,18 +1888,18 @@ CWD_API char *tsrm_realpath(const char *path, char *real_path TSRMLS_DC) /* {{{
if (!*path) {
new_state.cwd = (char*)malloc(1);
new_state.cwd[0] = '\0';
new_state.cwd_length = 0;
if (VCWD_GETCWD(cwd, MAXPATHLEN)) {
path = cwd;
new_state.cwd_length = 0;
if (VCWD_GETCWD(cwd, MAXPATHLEN)) {
path = cwd;
}
} else if (!IS_ABSOLUTE_PATH(path, strlen(path)) &&
VCWD_GETCWD(cwd, MAXPATHLEN)) {
VCWD_GETCWD(cwd, MAXPATHLEN)) {
new_state.cwd = strdup(cwd);
new_state.cwd_length = strlen(cwd);
} else {
new_state.cwd = (char*)malloc(1);
new_state.cwd[0] = '\0';
new_state.cwd_length = 0;
new_state.cwd_length = 0;
}
if (virtual_file_ex(&new_state, path, NULL, CWD_REALPATH)) {
+13 -9
View File
@@ -14,6 +14,7 @@
+----------------------------------------------------------------------+
| Authors: Andi Gutmans <andi@zend.com> |
| Sascha Schumann <sascha@schumann.cx> |
| Pierre Joye <pierre@php.net> |
+----------------------------------------------------------------------+
*/
@@ -107,7 +108,7 @@ typedef unsigned short mode_t;
#define COPY_WHEN_ABSOLUTE(path) 0
#endif
#ifndef IS_ABSOLUTE_PATH
#ifndef IS_ABSOLUTE_PATH
#define IS_ABSOLUTE_PATH(path, len) \
(IS_SLASH(path[0]))
#endif
@@ -129,9 +130,16 @@ typedef unsigned short mode_t;
#endif
#ifdef TSRM_WIN32
CWD_API int php_sys_stat_ex(const char *path, struct stat *buf, int lstat);
CWD_API int php_sys_stat(const char *path, struct stat *buf);
CWD_API int php_sys_lstat(const char *path, struct stat *buf);
CWD_API int php_sys_readlink(const char *link, char *target, size_t target_len);
#else
# define php_sys_stat stat
# define php_sys_lstat lstat
# ifdef HAVE_SYMLINK
# define php_sys_readlink(link, target, target_len) readlink(link, target, target_len)
# endif
#endif
typedef struct _cwd_state {
@@ -155,9 +163,7 @@ CWD_API int virtual_open(const char *path TSRMLS_DC, int flags, ...);
CWD_API int virtual_creat(const char *path, mode_t mode TSRMLS_DC);
CWD_API int virtual_rename(char *oldname, char *newname TSRMLS_DC);
CWD_API int virtual_stat(const char *path, struct stat *buf TSRMLS_DC);
#if !defined(TSRM_WIN32)
CWD_API int virtual_lstat(const char *path, struct stat *buf TSRMLS_DC);
#endif
CWD_API int virtual_unlink(const char *path TSRMLS_DC);
CWD_API int virtual_mkdir(const char *pathname, mode_t mode TSRMLS_DC);
CWD_API int virtual_rmdir(const char *pathname TSRMLS_DC);
@@ -188,7 +194,7 @@ CWD_API int virtual_chmod(const char *filename, mode_t mode TSRMLS_DC);
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group, int link TSRMLS_DC);
#endif
/* One of the following constants must be used as the last argument
/* One of the following constants must be used as the last argument
in virtual_file_ex() call. */
#define CWD_EXPAND 0 /* expand "." and ".." but dont resolve symlinks */
@@ -216,7 +222,7 @@ typedef struct _realpath_cache_bucket {
unsigned char is_wvalid;
unsigned char is_writable;
#endif
struct _realpath_cache_bucket *next;
struct _realpath_cache_bucket *next;
} realpath_cache_bucket;
typedef struct _virtual_cwd_globals {
@@ -244,7 +250,7 @@ CWD_API realpath_cache_bucket** realpath_cache_get_buckets(TSRMLS_D);
/* The actual macros to be used in programs using TSRM
* If the program defines VIRTUAL_DIR it will use the
* virtual_* functions
* virtual_* functions
*/
#ifdef VIRTUAL_DIR
@@ -261,9 +267,7 @@ CWD_API realpath_cache_bucket** realpath_cache_get_buckets(TSRMLS_D);
#define VCWD_REALPATH(path, real_path) virtual_realpath(path, real_path TSRMLS_CC)
#define VCWD_RENAME(oldname, newname) virtual_rename(oldname, newname TSRMLS_CC)
#define VCWD_STAT(path, buff) virtual_stat(path, buff TSRMLS_CC)
#if !defined(TSRM_WIN32)
# define VCWD_LSTAT(path, buff) virtual_lstat(path, buff TSRMLS_CC)
#endif
#define VCWD_LSTAT(path, buff) virtual_lstat(path, buff TSRMLS_CC)
#define VCWD_UNLINK(path) virtual_unlink(path TSRMLS_CC)
#define VCWD_MKDIR(pathname, mode) virtual_mkdir(pathname, mode TSRMLS_CC)
#define VCWD_RMDIR(pathname) virtual_rmdir(pathname TSRMLS_CC)
+13
View File
@@ -40,6 +40,9 @@ UPGRADE NOTES - PHP 5.3
2. Changes made to existing functions
=====================================
- Paths containing NULL (like /some/path\0foo.txt) are now considered invalid.
See http://news.php.net/php.internals/50191
- The HTTP stream wrapper now considers all status codes from 200 to 399 to be
successful.
@@ -273,6 +276,8 @@ UPGRADE NOTES - PHP 5.3
- MySQLi: Now supports persistent connections by prepending the hostname
with "p:".
- imagepstext now rejects invalid antialiasing steps and raises a warning.
d. no longer possible to disable
- PCRE
@@ -457,6 +462,14 @@ UPGRADE NOTES - PHP 5.3
- Firebird and SNMP support are no longer available on Windows. Firebird support
may be reintroduced in the future.
=====================
11.1 New in PHP 5.3.4
=====================
- open_basedir supports now symbolic links (checks the target).
- is_link and SplFileInfo symbolic links related method are now fully supported
(on Windows Vista or later).
===================
12. New in PHP 5.3:
===================
+23
View File
@@ -0,0 +1,23 @@
$Id$
UPGRADE NOTES - PHP 5.3.4
1. Internal API changes
========================
1. Internal API changes
========================
a. stat/lstat support
lstat is now available on all platforms. On unix-like platform
php_sys_lstat is an alias to lstat (when avaible). On Windows it is now
available using php_sys_lstat. php_sys_stat and php_sys_lstat usage is recommended
instead of calling lstat directly, to ensure portability.
b. readlink support
readlink is now available on all platforms. On unix-like platform
php_sys_readlink is an alias to readlink (when avaible). On Windows it is now
available using php_sys_readlink. php_sys_readlink usage is recommended
instead of calling readlink directly, to ensure portability.
+1 -1
View File
@@ -4,7 +4,7 @@ dnl This file contains local autoconf functions.
AC_DEFUN([LIBZEND_BISON_CHECK],[
# we only support certain bison versions
bison_version_list="1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3 2.4 2.4.1"
bison_version_list="1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3 2.4 2.4.1 2.4.2 2.4.3"
# for standalone build of Zend Engine
test -z "$SED" && SED=sed
+2 -16
View File
@@ -17,22 +17,8 @@ array(1) {
[0]=>
int(2)
[1]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
[2]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
}
}
+4 -33
View File
@@ -20,46 +20,17 @@ array(3) {
[0]=>
int(2)
[1]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
[2]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
}
[2]=>
&array(3) {
[0]=>
int(2)
[1]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
[2]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
}
}
+4 -18
View File
@@ -11,29 +11,15 @@ var_dump($a);
$a->b = null;
$a = null;
?>
--EXPECT--
object(stdClass)#1 (1) {
--EXPECTF--
object(stdClass)#%d (1) {
["b"]=>
&array(3) {
[0]=>
int(2)
[1]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
[2]=>
&array(3) {
[0]=>
int(2)
[1]=>
*RECURSION*
[2]=>
*RECURSION*
}
*RECURSION*
}
}
+5 -19
View File
@@ -12,30 +12,16 @@ var_dump($a);
$a->x0->y1 = "ok\n";
echo $a->x0;
?>
--EXPECT--
object(stdClass)#1 (1) {
--EXPECTF--
object(stdClass)#%d (1) {
["x0"]=>
&object(stdClass)#2 (3) {
&object(stdClass)#%d (3) {
["y0"]=>
string(1) "b"
["y1"]=>
&object(stdClass)#2 (3) {
["y0"]=>
string(1) "b"
["y1"]=>
*RECURSION*
["y2"]=>
*RECURSION*
}
*RECURSION*
["y2"]=>
&object(stdClass)#2 (3) {
["y0"]=>
string(1) "b"
["y1"]=>
*RECURSION*
["y2"]=>
*RECURSION*
}
*RECURSION*
}
}
ok
+4 -2
View File
@@ -30,7 +30,9 @@ if (defined("pass3")) {
set_error_handler('errorHandler');
define("pass2", 1);
include(__FILE__);
print "ok\n";
}
?>
--EXPECTF--
Error: Redefining already defined constructor for class TestClass (%sbug35634.php:12)
--EXPECT--
ok
+4 -4
View File
@@ -43,11 +43,11 @@ __call:
string(3) "ABC"
__call:
string(3) "ABC"
__callstatic:
__call:
string(3) "XYZ"
__callstatic:
__call:
string(3) "WWW"
__callstatic:
__call:
string(3) "ABC"
__callstatic:
string(1) "A"
@@ -58,4 +58,4 @@ string(1) "C"
__callstatic:
string(3) "FOO"
__callstatic:
string(3) "FOO"
string(3) "FOO"
+4 -4
View File
@@ -35,17 +35,17 @@ call_user_func('self::y');
?>
--EXPECTF--
__callstatic:
__call:
string(3) "ABC"
__callstatic:
__call:
string(3) "ABC"
__call:
string(3) "xyz"
__callstatic:
__call:
string(3) "www"
__call:
string(1) "y"
__callstatic:
__call:
string(1) "y"
ok
__callstatic:
-2
View File
@@ -29,8 +29,6 @@ $b->A();
?>
===DONE===
--EXPECTF--
Strict Standards: Redefining already defined constructor for class A in %s on line %d
B::__construct
A::__construct
B::A
-3
View File
@@ -16,7 +16,4 @@ $c = new c();
?>
===DONE===
--EXPECTF--
Strict Standards: Redefining already defined constructor for class a in %s on line %d
Fatal error: Call to undefined method b::b() in %s on line %d
+16
View File
@@ -0,0 +1,16 @@
--TEST--
Bug #48930 (__COMPILER_HALT_OFFSET__ incorrect in PHP>=5.3)
--FILE--
#!php
<?php
/*
* Test
*/
printf("__COMPILER_HALT_OFFSET__ is %d\n",__COMPILER_HALT_OFFSET__);
__halt_compiler();
?>
--EXPECT--
__COMPILER_HALT_OFFSET__ is 116
+28
View File
@@ -0,0 +1,28 @@
--TEST--
Bug #49893 (Crash while creating an instance of Zend_Mail_Storage_Pop3)
--FILE--
<?php
class A {
function __destruct() {
try {
throw new Exception("2");
} catch (Exception $e) {
echo $e->getMessage() . "\n";
}
}
}
class B {
function __construct() {
$this->a = new A();
throw new Exception("1");
}
}
try {
$b = new B();
} catch(Exception $e) {
echo $e->getMessage() . "\n";;
}
?>
--EXPECT--
2
1
+3 -3
View File
@@ -27,6 +27,6 @@ $foo->start();
?>
--EXPECT--
static
static
static
instance
instance
instance
+16
View File
@@ -0,0 +1,16 @@
--TEST--
Bug #51394 (Error line reported incorrectly if error handler throws an exception)
--INI--
error_reporting=-1
--FILE--
<?php
function eh()
{
throw new Exception("error!");
return false;
}
set_error_handler("eh");
$a = $empty($b);
--EXPECTF--
Fatal error: Function name must be a string in %sbug51394.php on line 9
+14
View File
@@ -0,0 +1,14 @@
--TEST--
Bug #51791 (constant() failed to check undefined constant and php interpreter stoped)
--FILE--
<?php
class A {
const B = 1;
}
var_dump(constant('A::B1'));
?>
--EXPECTF--
Warning: constant(): Couldn't find constant A::B1 in %s on line %d
NULL
+40
View File
@@ -0,0 +1,40 @@
--TEST--
Bug #51822 (Segfault with strange __destruct() for static class variables)
--FILE--
<?php
class DestructableObject
{
public function __destruct()
{
echo "2\n";
}
}
class DestructorCreator
{
public function __destruct()
{
$this->test = new DestructableObject;
echo "1\n";
}
}
class Test
{
public static $mystatic;
}
// Uncomment this to avoid segfault
//Test::$mystatic = new DestructorCreator();
$x = new Test();
if (!isset(Test::$mystatic))
Test::$mystatic = new DestructorCreator();
echo "bla\n";
?>
--EXPECT--
bla
1
2
+19
View File
@@ -0,0 +1,19 @@
--TEST--
Bug #51827 (Bad warning when register_shutdown_function called with wrong num of parameters)
--FILE--
<?php
function abc() {
var_dump(1);
}
register_shutdown_function('timE');
register_shutdown_function('ABC');
register_shutdown_function('exploDe');
?>
--EXPECTF--
int(1)
Warning: explode() expects at least 2 parameters, 0 given in Unknown on line %d
+17
View File
@@ -0,0 +1,17 @@
--TEST--
Bug #52001 (Memory allocation problems after using variable variables)
--FILE--
<?php
a(0,$$var);
$temp1=1;
$temp2=2;
var_dump($temp1);
function a($b,$c) {}
?>
--EXPECTF--
Notice: Undefined variable: var in %sbug52001.php on line 2
Notice: Undefined variable: in %sbug52001.php on line 2
int(1)
+50
View File
@@ -0,0 +1,50 @@
--TEST--
Bug #52041 (Memory leak when writing on uninitialized variable returned from function)
--FILE--
<?php
function foo() {
return $x;
}
foo()->a = 1;
foo()->a->b = 2;
foo()->a++;
foo()->a->b++;
foo()->a += 2;
foo()->a->b += 2;
//foo()[0] = 1;
//foo()[0][0] = 2;
//foo()[0]++;
//foo()[0][0]++;
//foo()[0] += 2;
//foo()[0][0] += 2;
var_dump(foo());
?>
--EXPECTF--
Notice: Undefined variable: x in %sbug52041.php on line 3
Strict Standards: Creating default object from empty value in %sbug52041.php on line 6
Notice: Undefined variable: x in %sbug52041.php on line 3
Strict Standards: Creating default object from empty value in %sbug52041.php on line 7
Notice: Undefined variable: x in %sbug52041.php on line 3
Strict Standards: Creating default object from empty value in %sbug52041.php on line 8
Notice: Undefined variable: x in %sbug52041.php on line 3
Strict Standards: Creating default object from empty value in %sbug52041.php on line 9
Notice: Undefined variable: x in %sbug52041.php on line 3
Strict Standards: Creating default object from empty value in %sbug52041.php on line 10
Notice: Undefined variable: x in %sbug52041.php on line 3
Strict Standards: Creating default object from empty value in %sbug52041.php on line 11
Notice: Undefined variable: x in %sbug52041.php on line 3
NULL
+27
View File
@@ -0,0 +1,27 @@
--TEST--
Bug #52051 (handling of case sensitivity of old-style constructors changed in 5.3+)
--FILE--
<?php
class AA {
function AA() { echo "foo\n"; }
}
class bb extends AA {}
class CC extends bb {
function CC() { parent::bb(); }
}
new CC();
class A {
function A() { echo "bar\n"; }
}
class B extends A {}
class C extends B {
function C() { parent::B(); }
}
new C();
?>
--EXPECT--
foo
bar
+12
View File
@@ -0,0 +1,12 @@
--TEST--
Bug #52060 (Memory leak when passing a closure to method_exists())
--FILE--
<?php
$closure = function($a) { echo $a; };
var_dump(method_exists($closure, '__invoke')); // true
?>
--EXPECT--
bool(true)
+34
View File
@@ -0,0 +1,34 @@
--TEST--
Bug #52160 (Invalid E_STRICT redefined constructor error)
--FILE--
<?php
class bar {
function __construct() { }
static function bar() {
var_dump(1);
}
}
bar::bar();
class foo {
static function foo() {
var_dump(2);
}
function __construct() { }
}
foo::foo();
class baz {
static function baz() {
var_dump(3);
}
}
?>
--EXPECTF--
Strict Standards: Redefining already defined constructor for class foo in %s on line %d
Fatal error: Constructor baz::baz() cannot be static in %s on line %d
+78
View File
@@ -0,0 +1,78 @@
--TEST--
Bug #52193 (converting closure to array yields empty array)
--FILE--
<?php
var_dump((array) 1);
var_dump((array) NULL);
var_dump((array) new stdclass);
var_dump($h = (array) function () { return 2; });
var_dump($h[0]());
$i = function () use (&$h) {
return $h;
};
var_dump($x = (array)$i);
var_dump($y = $x[0]);
var_dump($y());
$items = range(1, 5);
$func = function(){ return 'just a test'; };
array_splice($items, 0 , 4, $func);
var_dump($items);
?>
--EXPECTF--
array(1) {
[0]=>
int(1)
}
array(0) {
}
array(0) {
}
array(1) {
[0]=>
object(Closure)#%d (0) {
}
}
int(2)
array(1) {
[0]=>
object(Closure)#%d (1) {
["static"]=>
array(1) {
["h"]=>
&array(1) {
[0]=>
object(Closure)#%d (0) {
}
}
}
}
}
object(Closure)#%d (1) {
["static"]=>
array(1) {
["h"]=>
&array(1) {
[0]=>
object(Closure)#%d (0) {
}
}
}
}
array(1) {
[0]=>
object(Closure)#%d (0) {
}
}
array(2) {
[0]=>
object(Closure)#%d (0) {
}
[1]=>
int(5)
}
+11
View File
@@ -0,0 +1,11 @@
--TEST--
Bug #52237 (Crash when passing the reference of the property of a non-object)
--FILE--
<?php
$data = 'test';
preg_match('//', '', $data->info);
var_dump($data);
?>
--EXPECTF--
Warning: Attempt to modify property of non-object in %sbug52237.php on line 3
string(4) "test"
+35
View File
@@ -0,0 +1,35 @@
--TEST--
Bug #52361 (Throwing an exception in a destructor causes invalid catching)
--FILE--
<?php
class aaa {
public function __destruct() {
try {
throw new Exception(__CLASS__);
} catch(Exception $ex) {
echo "1. $ex\n";
}
}
}
function bbb() {
$a = new aaa();
throw new Exception(__FUNCTION__);
}
try {
bbb();
echo "must be skipped !!!";
} catch(Exception $ex) {
echo "2. $ex\n";
}
?>
--EXPECTF--
1. exception 'Exception' with message 'aaa' in %sbug52361.php:5
Stack trace:
#0 %sbug52361.php(16): aaa->__destruct()
#1 %sbug52361.php(16): bbb()
#2 {main}
2. exception 'Exception' with message 'bbb' in %sbug52361.php:13
Stack trace:
#0 %sbug52361.php(16): bbb()
#1 {main}
+19
View File
@@ -0,0 +1,19 @@
--TEST--
Bug #52484 (__set() ignores setting properties with empty names)
--FILE--
<?php
class A {
function __unset($prop) {
unset($this->$prop);
}
}
$a = new A();
$prop = null;
unset($a->$prop);
?>
--EXPECTF--
Fatal error: Cannot access empty property in %s on line %d
+19
View File
@@ -0,0 +1,19 @@
--TEST--
Bug #52484.2 (__set() ignores setting properties with empty names)
--FILE--
<?php
class A {
function __set($prop, $val) {
$this->$prop = $val;
}
}
$a = new A();
$prop = null;
$a->$prop = 2;
?>
--EXPECTF--
Fatal error: Cannot access empty property in %s on line %d
+19
View File
@@ -0,0 +1,19 @@
--TEST--
Bug #52484.3 (__set() ignores setting properties with empty names)
--FILE--
<?php
class A {
function __get($prop) {
var_dump($this->$prop);
}
}
$a = new A();
$prop = null;
var_dump($a->$prop);
?>
--EXPECTF--
Fatal error: Cannot access empty property in %s on line %d
+20
View File
@@ -0,0 +1,20 @@
--TEST--
Bug #52508 (newline problem with parse_ini_file+INI_SCANNER_RAW)
--FILE--
<?php
$file = dirname(__FILE__) .'/bug52508.ini';
file_put_contents($file, "a = 1");
$ini_array = parse_ini_file($file, true, INI_SCANNER_RAW);
var_dump($ini_array);
unlink($file);
?>
--EXPECT--
array(1) {
["a"]=>
string(1) "1"
}
+16
View File
@@ -0,0 +1,16 @@
--TEST--
Bug #52879 (Objects unreferenced in __get, __set, __isset or __unset can be freed too early)
--FILE--
<?php
class MyClass {
public $myRef;
public function __set($property,$value) {
$this->myRef = $value;
}
}
$myGlobal=new MyClass($myGlobal);
$myGlobal->myRef=&$myGlobal;
$myGlobal->myNonExistentProperty="ok\n";
echo $myGlobal;
--EXPECT--
ok
+40
View File
@@ -0,0 +1,40 @@
--TEST--
Bug #52939 (zend_call_function_array does not respect ZEND_SEND_PREFER_REF)
--FILE--
<?php
$ar1 = array("row1" => 2, "row2" => 1);
var_dump(array_multisort($ar1));
var_dump($ar1);
$ar1 = array("row1" => 2, "row2" => 1);
$args = array(&$ar1);
var_dump(call_user_func_array("array_multisort", $args));
var_dump($ar1);
$ar1 = array("row1" => 2, "row2" => 1);
$args = array($ar1);
var_dump(call_user_func_array("array_multisort", $args));
var_dump($ar1);
?>
--EXPECT--
bool(true)
array(2) {
["row2"]=>
int(1)
["row1"]=>
int(2)
}
bool(true)
array(2) {
["row2"]=>
int(1)
["row1"]=>
int(2)
}
bool(true)
array(2) {
["row1"]=>
int(2)
["row2"]=>
int(1)
}
+19
View File
@@ -0,0 +1,19 @@
--TEST--
Bug #53305 (E_NOTICE when defining a constant starts with __COMPILER_HALT_OFFSET__)
--FILE--
<?php
error_reporting(E_ALL);
define('__COMPILER_HALT_OFFSET__1', 1);
define('__COMPILER_HALT_OFFSET__2', 2);
define('__COMPILER_HALT_OFFSET__', 3);
define('__COMPILER_HALT_OFFSET__1'.chr(0), 4);
var_dump(__COMPILER_HALT_OFFSET__1);
var_dump(constant('__COMPILER_HALT_OFFSET__1'.chr(0)));
?>
--EXPECTF--
Notice: Constant __COMPILER_HALT_OFFSET__ already defined in %s on line %d
int(1)
int(4)
+2 -2
View File
@@ -28,9 +28,9 @@ foo::BAZ();
--EXPECT--
nonstatic
string(6) "fOoBaR"
static
nonstatic
string(6) "foOBAr"
static
nonstatic
string(6) "fOOBAr"
static
string(3) "bAr"
+1 -1
View File
@@ -30,5 +30,5 @@ a::Foo();
--EXPECT--
__callstatic: Test
__call: Test
__callstatic: Bar
__call: Bar
__callstatic: Foo
+1 -12
View File
@@ -31,18 +31,7 @@ object(foo)#%d (%d) {
["static"]=>
array(1) {
["a"]=>
&object(foo)#%d (2) {
["test":"foo":private]=>
int(3)
["a"]=>
object(Closure)#%d (1) {
["static"]=>
array(1) {
["a"]=>
*RECURSION*
}
}
}
*RECURSION*
}
}
}
+2 -8
View File
@@ -9,17 +9,11 @@ var_dump($a);
?>
===DONE===
--EXPECTF--
object(Closure)#1 (1) {
object(Closure)#%d (1) {
["static"]=>
array(1) {
["a"]=>
&object(Closure)#1 (1) {
["static"]=>
array(1) {
["a"]=>
*RECURSION*
}
}
*RECURSION*
}
}
===DONE===
+2 -8
View File
@@ -18,14 +18,8 @@ var_dump($x());
object(Closure)#%d (1) {
["static"]=>
array(1) {
[%u|b%"x"]=>
&object(Closure)#%d (1) {
["static"]=>
array(1) {
[%u|b%"x"]=>
*RECURSION*
}
}
["x"]=>
*RECURSION*
}
}
int(1)
+6
View File
@@ -1,5 +1,11 @@
--TEST--
Testing declare statement with several type values
--SKIPIF--
<?php
if (in_array("detect_unicode", array_keys(ini_get_all()))) {
die("skip");
}
?>
--FILE--
<?php
+1 -4
View File
@@ -15,9 +15,6 @@ array(1) {
["a"]=>
&array(1) {
["a"]=>
&array(1) {
["a"]=>
*RECURSION*
}
*RECURSION*
}
}
+1 -4
View File
@@ -16,10 +16,7 @@ array(1) {
[0]=>
&array(1) {
[0]=>
&array(1) {
[0]=>
*RECURSION*
}
*RECURSION*
}
}
int(1)
+3 -6
View File
@@ -11,13 +11,10 @@ unset($a);
var_dump(gc_collect_cycles());
echo "ok\n"
?>
--EXPECT--
object(stdClass)#1 (1) {
--EXPECTF--
object(stdClass)#%d (1) {
["a"]=>
object(stdClass)#1 (1) {
["a"]=>
*RECURSION*
}
*RECURSION*
}
int(1)
ok
+3 -9
View File
@@ -12,18 +12,12 @@ unset($a);
var_dump(gc_collect_cycles());
echo "ok\n"
?>
--EXPECT--
object(stdClass)#1 (1) {
--EXPECTF--
object(stdClass)#%d (1) {
["a"]=>
array(1) {
[0]=>
&object(stdClass)#1 (1) {
["a"]=>
array(1) {
[0]=>
*RECURSION*
}
}
*RECURSION*
}
}
int(2)
+1 -4
View File
@@ -17,10 +17,7 @@ array(1) {
[0]=>
&array(1) {
[0]=>
&array(1) {
[0]=>
*RECURSION*
}
*RECURSION*
}
}
int(0)
+3 -6
View File
@@ -13,13 +13,10 @@ unset($a);
var_dump(gc_collect_cycles());
echo "ok\n"
?>
--EXPECT--
object(stdClass)#2 (1) {
--EXPECTF--
object(stdClass)#%d (1) {
["a"]=>
object(stdClass)#2 (1) {
["a"]=>
*RECURSION*
}
*RECURSION*
}
int(0)
int(1)
+3 -9
View File
@@ -14,18 +14,12 @@ unset($a);
var_dump(gc_collect_cycles());
echo "ok\n"
?>
--EXPECT--
object(stdClass)#1 (1) {
--EXPECTF--
object(stdClass)#%d (1) {
["a"]=>
array(1) {
[0]=>
&object(stdClass)#1 (1) {
["a"]=>
array(1) {
[0]=>
*RECURSION*
}
}
*RECURSION*
}
}
int(0)
+1 -4
View File
@@ -17,10 +17,7 @@ array(1) {
[0]=>
&array(1) {
[0]=>
&array(1) {
[0]=>
*RECURSION*
}
*RECURSION*
}
}
int(1)
+3 -6
View File
@@ -17,13 +17,10 @@ unset($a);
var_dump(gc_collect_cycles());
echo "ok\n"
?>
--EXPECT--
object(Foo)#1 (1) {
--EXPECTF--
object(Foo)#%d (1) {
["a"]=>
object(Foo)#1 (1) {
["a"]=>
*RECURSION*
}
*RECURSION*
}
__destruct
int(1)
+40
View File
@@ -0,0 +1,40 @@
--TEST--
GC 032: Crash in GC because of invalid reference counting
--FILE--
<?php
$a = array();
$b =& $a;
$a[0] = $a;
debug_zval_dump($a);
$a = array(array());
$b =& $a;
$a[0][0] = $a;
debug_zval_dump($a);
?>
--EXPECT--
array(1) refcount(1){
[0]=>
array(1) refcount(3){
[0]=>
array(1) refcount(3){
[0]=>
*RECURSION*
}
}
}
array(1) refcount(1){
[0]=>
array(1) refcount(3){
[0]=>
array(1) refcount(1){
[0]=>
array(1) refcount(3){
[0]=>
array(1) refcount(1){
[0]=>
*RECURSION*
}
}
}
}
}
Binary file not shown.
+2 -1
View File
@@ -1,5 +1,5 @@
--TEST--
063: Support for old-style constructors in namesapces
063: Old-style constructors in namesapces (not supported!)
--FILE--
<?php
namespace Foo;
@@ -9,5 +9,6 @@ class Bar {
}
}
new Bar();
echo "ok\n";
--EXPECT--
ok
+1 -2
View File
@@ -14,6 +14,5 @@ class test {
echo "Done\n";
?>
--EXPECTF--
Strict Standards: Redefining already defined constructor for class test in %s on line %d
--EXPECT--
Done
+3 -11
View File
@@ -13,18 +13,10 @@ $$test->a->b[] = 2;
var_dump($$test);
?>
--EXPECT--
object(stdClass)#1 (2) {
--EXPECTF--
object(stdClass)#%d (2) {
["a"]=>
&object(stdClass)#1 (2) {
["a"]=>
*RECURSION*
["b"]=>
array(1) {
[0]=>
int(2)
}
}
*RECURSION*
["b"]=>
array(1) {
[0]=>
+40
View File
@@ -0,0 +1,40 @@
--TEST--
Covariant return-by-ref constraints
--FILE--
<?php
class A implements ArrayAccess {
public $foo = array();
public function &offsetGet($n) {
return $this->foo[$n];
}
public function offsetSet($n, $v) {
}
public function offsetUnset($n) {
}
public function offsetExists($n) {
}
}
$a = new A;
$a['foo']['bar'] = 2;
var_dump($a);
?>
==DONE==
--EXPECTF--
object(A)#1 (1) {
["foo"]=>
array(1) {
["foo"]=>
array(1) {
["bar"]=>
int(2)
}
}
}
==DONE==
+1 -1
View File
@@ -19,7 +19,7 @@ echo $HTTP_SESSION_VARS;
echo "\nok\n";
?>
--EXPECTF--
Warning: Directive 'register_long_arrays' is deprecated in PHP %d.%d and greater in Unknown on line 0
Deprecated: Directive 'register_long_arrays' is deprecated in PHP %d.%d and greater in Unknown on line 0
ok
Warning: session_start(): Cannot send session cookie - headers already sent by (output started at %sunset_cv05.php on line %d
+1 -1
View File
@@ -19,7 +19,7 @@ echo $x;
echo "ok\n";
?>
--EXPECTF--
Warning: Directive 'register_globals' is deprecated in PHP %d.%d and greater in Unknown on line 0
Deprecated: Directive 'register_globals' is deprecated in PHP %d.%d and greater in Unknown on line 0
1
Deprecated: Function session_register() is deprecated in %s on line %d
+23 -22
View File
@@ -251,22 +251,18 @@ ZEND_API int zend_get_object_classname(const zval *object, char **class_name, ze
}
/* }}} */
static int parse_arg_object_to_string(zval **arg, char **p, int *pl, int type TSRMLS_DC) /* {{{ */
static int parse_arg_object_to_string(zval **arg TSRMLS_DC) /* {{{ */
{
if (Z_OBJ_HANDLER_PP(arg, cast_object)) {
SEPARATE_ZVAL_IF_NOT_REF(arg);
if (Z_OBJ_HANDLER_PP(arg, cast_object)(*arg, *arg, type TSRMLS_CC) == SUCCESS) {
*pl = Z_STRLEN_PP(arg);
*p = Z_STRVAL_PP(arg);
if (Z_OBJ_HANDLER_PP(arg, cast_object)(*arg, *arg, IS_STRING TSRMLS_CC) == SUCCESS) {
return SUCCESS;
}
}
/* Standard PHP objects */
if (Z_OBJ_HT_PP(arg) == &std_object_handlers || !Z_OBJ_HANDLER_PP(arg, cast_object)) {
SEPARATE_ZVAL_IF_NOT_REF(arg);
if (zend_std_cast_object_tostring(*arg, *arg, type TSRMLS_CC) == SUCCESS) {
*pl = Z_STRLEN_PP(arg);
*p = Z_STRVAL_PP(arg);
if (zend_std_cast_object_tostring(*arg, *arg, IS_STRING TSRMLS_CC) == SUCCESS) {
return SUCCESS;
}
}
@@ -281,8 +277,6 @@ static int parse_arg_object_to_string(zval **arg, char **p, int *pl, int type TS
if (!use_copy) {
ZVAL_ZVAL(*arg, z, 1, 1);
}
*pl = Z_STRLEN_PP(arg);
*p = Z_STRVAL_PP(arg);
return SUCCESS;
}
zval_ptr_dtor(&z);
@@ -418,15 +412,17 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, char **sp
case IS_DOUBLE:
case IS_BOOL:
convert_to_string_ex(arg);
if (UNEXPECTED(Z_ISREF_PP(arg) != 0)) {
/* it's dangerous to return pointers to string
buffer of referenced variable, because it can
be clobbered throug magic callbacks */
SEPARATE_ZVAL(arg);
}
*p = Z_STRVAL_PP(arg);
*pl = Z_STRLEN_PP(arg);
break;
case IS_OBJECT:
if (parse_arg_object_to_string(arg, p, pl, IS_STRING TSRMLS_CC) == SUCCESS) {
break;
}
case IS_ARRAY:
case IS_RESOURCE:
default:
@@ -680,7 +676,7 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
int max_num_args = 0;
int post_varargs = 0;
zval **arg;
int arg_count;
int arg_count = (int)(zend_uintptr_t) *(zend_vm_stack_top(TSRMLS_C) - 1);
int quiet = flags & ZEND_PARSE_PARAMS_QUIET;
zend_bool have_varargs = 0;
zval ****varargs = NULL;
@@ -689,14 +685,21 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
for (spec_walk = type_spec; *spec_walk; spec_walk++) {
c = *spec_walk;
switch (c) {
case 's':
if (max_num_args < arg_count) {
arg = (zval **) (zend_vm_stack_top(TSRMLS_C) - 1 - (arg_count - max_num_args));
if (Z_TYPE_PP(arg) == IS_OBJECT) {
parse_arg_object_to_string(arg TSRMLS_CC);
}
}
/* break missing intentionally */
case 'l': case 'd':
case 's': case 'b':
case 'H': case 'b':
case 'r': case 'a':
case 'o': case 'O':
case 'z': case 'Z':
case 'C': case 'h':
case 'f': case 'A':
case 'H':
max_num_args++;
break;
@@ -718,7 +721,7 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
zend_error(E_WARNING, "%s%s%s(): only one varargs specifier (* or +) is permitted",
class_name,
class_name[0] ? "::" : "",
get_active_function_name(TSRMLS_C));
active_function->common.function_name);
}
return FAILURE;
}
@@ -738,7 +741,7 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
zend_error(E_WARNING, "%s%s%s(): bad type specifier while parsing parameters",
class_name,
class_name[0] ? "::" : "",
get_active_function_name(TSRMLS_C));
active_function->common.function_name);
}
return FAILURE;
}
@@ -761,7 +764,7 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
zend_error(E_WARNING, "%s%s%s() expects %s %d parameter%s, %d given",
class_name,
class_name[0] ? "::" : "",
get_active_function_name(TSRMLS_C),
active_function->common.function_name,
min_num_args == max_num_args ? "exactly" : num_args < min_num_args ? "at least" : "at most",
num_args < min_num_args ? min_num_args : max_num_args,
(num_args < min_num_args ? min_num_args : max_num_args) == 1 ? "" : "s",
@@ -770,8 +773,6 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
return FAILURE;
}
arg_count = (int)(zend_uintptr_t) *(zend_vm_stack_top(TSRMLS_C) - 1);
if (num_args > arg_count) {
zend_error(E_WARNING, "%s(): could not obtain parameters for parsing",
get_active_function_name(TSRMLS_C));
@@ -1081,7 +1082,7 @@ ZEND_API int _object_and_properties_init(zval *arg, zend_class_entry *class_type
} else {
ALLOC_HASHTABLE_REL(object->properties);
zend_hash_init(object->properties, zend_hash_num_elements(&class_type->default_properties), NULL, ZVAL_PTR_DTOR, 0);
zend_hash_copy(object->properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
zend_hash_copy(object->properties, &class_type->default_properties, zval_copy_property_ctor(class_type), (void *) &tmp, sizeof(zval *));
}
} else {
Z_OBJVAL_P(arg) = class_type->create_object(class_type TSRMLS_CC);
+1 -1
View File
@@ -1115,7 +1115,7 @@ ZEND_API zend_mm_heap *zend_mm_startup_ex(const zend_mm_mem_handlers *handlers,
mm_heap->large_free_buckets[i]->parent = &mm_heap->large_free_buckets[i];
}
}
mm_heap->rest_buckets[0]->next_free_block = mm_heap->rest_buckets[1]->prev_free_block = ZEND_MM_REST_BUCKET(mm_heap);
mm_heap->rest_buckets[0] = mm_heap->rest_buckets[1] = ZEND_MM_REST_BUCKET(mm_heap);
free(heap);
heap = mm_heap;
+13 -5
View File
@@ -26,6 +26,7 @@
#include "zend_ini.h"
#include "zend_exceptions.h"
#include "zend_extensions.h"
#include "zend_closures.h"
#undef ZEND_TEST_EXCEPTIONS
@@ -179,7 +180,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_alias, 0, 0, 2)
ZEND_END_ARG_INFO()
ZEND_BEGIN_ARG_INFO_EX(arginfo_trigger_error, 0, 0, 1)
ZEND_ARG_INFO(0, messsage)
ZEND_ARG_INFO(0, message)
ZEND_ARG_INFO(0, error_type)
ZEND_END_ARG_INFO()
@@ -1098,22 +1099,29 @@ ZEND_FUNCTION(method_exists)
RETURN_TRUE;
} else {
union _zend_function *func = NULL;
efree(lcname);
if (Z_TYPE_P(klass) == IS_OBJECT
&& Z_OBJ_HT_P(klass)->get_method != NULL
&& (func = Z_OBJ_HT_P(klass)->get_method(&klass, method_name, method_len TSRMLS_CC)) != NULL
) {
if (func->type == ZEND_INTERNAL_FUNCTION
&& ((zend_internal_function*)func)->handler == zend_std_call_user_call
&& (func->common.fn_flags & ZEND_ACC_CALL_VIA_HANDLER) != 0
) {
/* Returns true to the fake Closure's __invoke */
RETVAL_BOOL((func->common.scope == zend_ce_closure
&& (method_len == sizeof(ZEND_INVOKE_FUNC_NAME)-1)
&& memcmp(lcname, ZEND_INVOKE_FUNC_NAME, sizeof(ZEND_INVOKE_FUNC_NAME)-1) == 0) ? 1 : 0);
efree(lcname);
efree(((zend_internal_function*)func)->function_name);
efree(func);
RETURN_FALSE;
return;
}
efree(lcname);
RETURN_TRUE;
}
}
efree(lcname);
RETURN_FALSE;
}
/* }}} */
@@ -1384,7 +1392,7 @@ ZEND_FUNCTION(get_included_files)
/* }}} */
/* {{{ proto void trigger_error(string messsage [, int error_type])
/* {{{ proto void trigger_error(string message [, int error_type])
Generates a user-level error/warning/notice message */
ZEND_FUNCTION(trigger_error)
{
+23 -24
View File
@@ -1270,25 +1270,14 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n
}
}
} else {
char *short_class_name;
int short_class_name_length;
char *short_class_lcname;
if ((short_class_name = zend_memrchr(CG(active_class_entry)->name, '\\', CG(active_class_entry)->name_length))) {
short_class_name_length = CG(active_class_entry)->name_length - (short_class_name - CG(active_class_entry)->name) - 1;
++short_class_name;
} else {
short_class_name = CG(active_class_entry)->name;
short_class_name_length = CG(active_class_entry)->name_length;
}
short_class_lcname = do_alloca(short_class_name_length + 1, use_heap);
zend_str_tolower_copy(short_class_lcname, short_class_name, short_class_name_length);
char *class_lcname;
class_lcname = do_alloca(CG(active_class_entry)->name_length + 1, use_heap);
zend_str_tolower_copy(class_lcname, CG(active_class_entry)->name, CG(active_class_entry)->name_length);
/* Improve after RC: cache the lowercase class name */
if ((short_class_name_length == name_len) && (!memcmp(short_class_lcname, lcname, name_len))) {
if (CG(active_class_entry)->constructor) {
zend_error(E_STRICT, "Redefining already defined constructor for class %s", CG(active_class_entry)->name);
} else {
if ((CG(active_class_entry)->name_length == name_len) && (!memcmp(class_lcname, lcname, name_len))) {
if (!CG(active_class_entry)->constructor) {
CG(active_class_entry)->constructor = (zend_function *) CG(active_op_array);
}
} else if ((name_len == sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_CONSTRUCTOR_FUNC_NAME, sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)))) {
@@ -1338,7 +1327,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n
} else if (!(fn_flags & ZEND_ACC_STATIC)) {
CG(active_op_array)->fn_flags |= ZEND_ACC_ALLOW_STATIC;
}
free_alloca(short_class_lcname, use_heap);
free_alloca(class_lcname, use_heap);
}
efree(lcname);
@@ -2543,13 +2532,16 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c
{
zend_uint i;
/* If it's a user function then arg_info == NULL means we don't have any parameters but we still need to do the arg number checks. We are only willing to ignore this for internal functions because extensions don't always define arg_info. */
/* If it's a user function then arg_info == NULL means we don't have any parameters but
* we still need to do the arg number checks. We are only willing to ignore this for internal
* functions because extensions don't always define arg_info.
*/
if (!proto || (!proto->common.arg_info && proto->common.type != ZEND_USER_FUNCTION)) {
return 1;
}
/* Checks for constructors only if they are declared in an interface */
if ((fe->common.fn_flags & ZEND_ACC_CTOR) && !(proto->common.scope->ce_flags & ZEND_ACC_INTERFACE)) {
if ((fe->common.fn_flags & ZEND_ACC_CTOR) && (proto->common.scope->ce_flags & ZEND_ACC_INTERFACE) == 0) {
return 1;
}
@@ -2559,12 +2551,14 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c
return 0;
}
if (proto->common.pass_rest_by_reference
if (fe->common.type != ZEND_USER_FUNCTION
&& proto->common.pass_rest_by_reference
&& !fe->common.pass_rest_by_reference) {
return 0;
}
if (fe->common.return_reference != proto->common.return_reference) {
/* by-ref constraints on return values are covariant */
if (proto->common.return_reference && !fe->common.return_reference) {
return 0;
}
@@ -2588,6 +2582,8 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c
/* Only one has an array type hint and the other one doesn't */
return 0;
}
/* by-ref constraints on arguments are invariant */
if (fe->common.arg_info[i].pass_by_reference != proto->common.arg_info[i].pass_by_reference) {
return 0;
}
@@ -2825,6 +2821,9 @@ static int inherit_static_prop(zval **p TSRMLS_DC, int num_args, va_list args, c
}
/* }}} */
#define zval_property_ctor(parent_ce, ce) \
((copy_ctor_func_t) (((parent_ce)->type != (ce)->type) ? zval_shared_property_ctor : zval_add_ref))
ZEND_API void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent_ce TSRMLS_DC) /* {{{ */
{
if ((ce->ce_flags & ZEND_ACC_INTERFACE)
@@ -2848,7 +2847,7 @@ ZEND_API void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent
zend_do_inherit_interfaces(ce, parent_ce TSRMLS_CC);
/* Inherit properties */
zend_hash_merge(&ce->default_properties, &parent_ce->default_properties, (void (*)(void *)) zval_add_ref, NULL, sizeof(zval *), 0);
zend_hash_merge(&ce->default_properties, &parent_ce->default_properties, zval_property_ctor(parent_ce, ce), NULL, sizeof(zval *), 0);
if (parent_ce->type != ce->type) {
/* User class extends internal class */
zend_update_class_constants(parent_ce TSRMLS_CC);
@@ -2858,7 +2857,7 @@ ZEND_API void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent
}
zend_hash_merge_ex(&ce->properties_info, &parent_ce->properties_info, (copy_ctor_func_t) (ce->type & ZEND_INTERNAL_CLASS ? zend_duplicate_property_info_internal : zend_duplicate_property_info), sizeof(zend_property_info), (merge_checker_func_t) do_inherit_property_access_check, ce);
zend_hash_merge(&ce->constants_table, &parent_ce->constants_table, (void (*)(void *)) zval_add_ref, NULL, sizeof(zval *), 0);
zend_hash_merge(&ce->constants_table, &parent_ce->constants_table, zval_property_ctor(parent_ce, ce), NULL, sizeof(zval *), 0);
zend_hash_merge_ex(&ce->function_table, &parent_ce->function_table, (copy_ctor_func_t) do_inherit_method, sizeof(zend_function), (merge_checker_func_t) do_inherit_method_check, ce);
do_inherit_parent_constructor(ce);
+3 -3
View File
@@ -687,9 +687,9 @@ int zendlex(znode *zendlval TSRMLS_DC);
#define ZEND_CT (1<<0)
#define ZEND_RT (1<<1)
#define ZEND_FETCH_STANDARD 0
#define ZEND_FETCH_ADD_LOCK (1<<0)
#define ZEND_FETCH_MAKE_REF (1<<1)
#define ZEND_FETCH_STANDARD 0x00000000
#define ZEND_FETCH_ADD_LOCK 0x08000000
#define ZEND_FETCH_MAKE_REF 0x04000000
#define ZEND_FE_FETCH_BYREF 1
#define ZEND_FE_FETCH_WITH_KEY 2
+10 -2
View File
@@ -434,8 +434,16 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC)
}
}
if ((strncmp(name, "__COMPILER_HALT_OFFSET__", sizeof("__COMPILER_HALT_OFFSET__") - 1) == 0) ||
zend_hash_add(EG(zend_constants), name, c->name_len, (void *) c, sizeof(zend_constant), NULL)==FAILURE) {
/* Check if the user is trying to define the internal pseudo constant name __COMPILER_HALT_OFFSET__ */
if ((c->name_len == sizeof("__COMPILER_HALT_OFFSET__")
&& !memcmp(name, "__COMPILER_HALT_OFFSET__", sizeof("__COMPILER_HALT_OFFSET__")-1))
|| zend_hash_add(EG(zend_constants), name, c->name_len, (void *) c, sizeof(zend_constant), NULL)==FAILURE) {
/* The internal __COMPILER_HALT_OFFSET__ is prefixed by NULL byte */
if (c->name[0] == '\0' && c->name_len > sizeof("\0__COMPILER_HALT_OFFSET__")
&& memcmp(name, "\0__COMPILER_HALT_OFFSET__", sizeof("\0__COMPILER_HALT_OFFSET__")) == 0) {
name++;
}
zend_error(E_NOTICE,"Constant %s already defined", name);
free(c->name);
if (!(c->flags & CONST_PERSISTENT)) {
+6 -5
View File
@@ -137,7 +137,7 @@ static zend_object_value zend_default_exception_new_ex(zend_class_entry *class_t
ALLOC_HASHTABLE(object->properties);
zend_hash_init(object->properties, 0, NULL, ZVAL_PTR_DTOR, 0);
zend_hash_copy(object->properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
zend_hash_copy(object->properties, &class_type->default_properties, zval_copy_property_ctor(class_type), (void *) &tmp, sizeof(zval *));
ALLOC_ZVAL(trace);
Z_UNSET_ISREF_P(trace);
@@ -572,6 +572,7 @@ ZEND_METHOD(exception, __toString)
zend_call_function(&fci, NULL TSRMLS_CC);
if (Z_TYPE_P(trace) != IS_STRING) {
zval_ptr_dtor(&trace);
trace = NULL;
}
@@ -592,6 +593,10 @@ ZEND_METHOD(exception, __toString)
zval_dtor(&line);
exception = zend_read_property(default_exception_ce, exception, "previous", sizeof("previous")-1, 0 TSRMLS_CC);
if (trace) {
zval_ptr_dtor(&trace);
}
}
zval_dtor(&fname);
@@ -599,10 +604,6 @@ ZEND_METHOD(exception, __toString)
* the result in uncaught exception handlers without memleaks. */
zend_update_property_string(default_exception_ce, getThis(), "string", sizeof("string")-1, str TSRMLS_CC);
if (trace) {
zval_ptr_dtor(&trace);
}
RETURN_STRINGL(str, len, 0);
}
/* }}} */
+2 -1
View File
@@ -708,13 +708,14 @@ static inline zval* zend_assign_to_variable(zval **variable_ptr_ptr, zval *value
return variable_ptr;
}
} else { /* we need to split */
GC_ZVAL_CHECK_POSSIBLE_ROOT(*variable_ptr_ptr);
if (!is_tmp_var) {
if (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) {
ALLOC_ZVAL(variable_ptr);
*variable_ptr_ptr = variable_ptr;
*variable_ptr = *value;
zval_copy_ctor(variable_ptr);
Z_SET_REFCOUNT_P(variable_ptr, 1);
zval_copy_ctor(variable_ptr);
} else {
*variable_ptr_ptr = value;
Z_ADDREF_P(value);
+2
View File
@@ -135,6 +135,8 @@ static inline int i_zend_is_true(zval *op)
}
ZEND_API int zval_update_constant(zval **pp, void *arg TSRMLS_DC);
ZEND_API int zval_update_constant_inline_change(zval **pp, void *arg TSRMLS_DC);
ZEND_API int zval_update_constant_no_inline_change(zval **pp, void *arg TSRMLS_DC);
ZEND_API int zval_update_constant_ex(zval **pp, void *arg, zend_class_entry *scope TSRMLS_DC);
/* dedicated Zend executor functions - do not use! */
+19 -2
View File
@@ -411,6 +411,10 @@ ZEND_API char *zend_get_executed_filename(TSRMLS_D) /* {{{ */
ZEND_API uint zend_get_executed_lineno(TSRMLS_D) /* {{{ */
{
if(EG(exception) && EG(opline_ptr) && active_opline->opcode == ZEND_HANDLE_EXCEPTION &&
active_opline->lineno == 0 && EG(opline_before_exception)) {
return EG(opline_before_exception)->lineno;
}
if (EG(opline_ptr)) {
return active_opline->lineno;
} else {
@@ -680,13 +684,25 @@ ZEND_API int zval_update_constant_ex(zval **pp, void *arg, zend_class_entry *sco
}
zval_dtor(&const_value);
}
zend_hash_apply_with_argument(Z_ARRVAL_P(p), (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
zend_hash_apply_with_argument(Z_ARRVAL_P(p), (apply_func_arg_t) zval_update_constant_inline_change, (void *) scope TSRMLS_CC);
zend_hash_internal_pointer_reset(Z_ARRVAL_P(p));
}
return 0;
}
/* }}} */
ZEND_API int zval_update_constant_inline_change(zval **pp, void *scope TSRMLS_DC) /* {{{ */
{
return zval_update_constant_ex(pp, (void*)1, scope TSRMLS_CC);
}
/* }}} */
ZEND_API int zval_update_constant_no_inline_change(zval **pp, void *scope TSRMLS_DC) /* {{{ */
{
return zval_update_constant_ex(pp, (void*)0, scope TSRMLS_CC);
}
/* }}} */
ZEND_API int zval_update_constant(zval **pp, void *arg TSRMLS_DC) /* {{{ */
{
return zval_update_constant_ex(pp, arg, NULL TSRMLS_CC);
@@ -854,7 +870,8 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
if (Z_REFCOUNT_PP(fci->params[i]) > 1) {
zval *new_zval;
if (fci->no_separation) {
if (fci->no_separation &&
!ARG_MAY_BE_SENT_BY_REF(EX(function_state).function, i + 1)) {
if(i) {
/* hack to clean up the stack */
zend_vm_stack_push_nocheck((void *) (zend_uintptr_t)i TSRMLS_CC);
+3 -1
View File
@@ -78,7 +78,9 @@ extern ZEND_API void zend_ensure_fpu_mode(TSRMLS_D);
# define HAVE__CONTROLFP
# endif /* MSC_VER >= 1500 */
/* Tell MSVC optimizer that we access FP environment */
# pragma fenv_access (on)
# if _MSC_VER >= 1500
# pragma fenv_access (on)
# endif
#endif /* _MSC_VER */
#ifdef HAVE__CONTROLFP_S
+63 -27
View File
@@ -282,7 +282,11 @@ tail_call:
GC_SET_BLACK(obj->buffered);
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
}
}
} else if (Z_TYPE_P(pz) == IS_ARRAY) {
@@ -313,7 +317,11 @@ static void zobj_scan_black(struct _store_object *obj, zval *pz TSRMLS_DC)
GC_SET_BLACK(obj->buffered);
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
while (p != NULL) {
pz = *(zval**)p->pData;
if (Z_TYPE_P(pz) != IS_ARRAY || Z_ARRVAL_P(pz) != &EG(symbol_table)) {
@@ -346,7 +354,11 @@ tail_call:
GC_SET_COLOR(obj->buffered, GC_GREY);
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
}
}
} else if (Z_TYPE_P(pz) == IS_ARRAY) {
@@ -380,7 +392,11 @@ static void zobj_mark_grey(struct _store_object *obj, zval *pz TSRMLS_DC)
GC_SET_COLOR(obj->buffered, GC_GREY);
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
while (p != NULL) {
pz = *(zval**)p->pData;
if (Z_TYPE_P(pz) != IS_ARRAY || Z_ARRVAL_P(pz) != &EG(symbol_table)) {
@@ -398,19 +414,21 @@ static void gc_mark_roots(TSRMLS_D)
gc_root_buffer *current = GC_G(roots).next;
while (current != &GC_G(roots)) {
if (current->handle && EG(objects_store).object_buckets) {
struct _store_object *obj = &EG(objects_store).object_buckets[current->handle].bucket.obj;
if (current->handle) {
if (EG(objects_store).object_buckets) {
struct _store_object *obj = &EG(objects_store).object_buckets[current->handle].bucket.obj;
if (GC_GET_COLOR(obj->buffered) == GC_PURPLE) {
zval z;
if (GC_GET_COLOR(obj->buffered) == GC_PURPLE) {
zval z;
INIT_PZVAL(&z);
Z_OBJ_HANDLE(z) = current->handle;
Z_OBJ_HT(z) = current->u.handlers;
zobj_mark_grey(obj, &z TSRMLS_CC);
} else {
GC_SET_ADDRESS(obj->buffered, NULL);
GC_REMOVE_FROM_BUFFER(current);
INIT_PZVAL(&z);
Z_OBJ_HANDLE(z) = current->handle;
Z_OBJ_HT(z) = current->u.handlers;
zobj_mark_grey(obj, &z TSRMLS_CC);
} else {
GC_SET_ADDRESS(obj->buffered, NULL);
GC_REMOVE_FROM_BUFFER(current);
}
}
} else {
if (GC_ZVAL_GET_COLOR(current->u.pz) == GC_PURPLE) {
@@ -445,7 +463,11 @@ tail_call:
GC_SET_COLOR(obj->buffered, GC_WHITE);
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return 0;
}
p = props->pListHead;
}
}
}
@@ -484,7 +506,11 @@ static void zobj_scan(zval *pz TSRMLS_DC)
GC_SET_COLOR(obj->buffered, GC_WHITE);
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
while (p != NULL) {
zval_scan(*(zval**)p->pData TSRMLS_CC);
p = p->pListNext;
@@ -531,7 +557,11 @@ tail_call:
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
}
}
} else {
@@ -572,7 +602,11 @@ static void zobj_collect_white(zval *pz TSRMLS_DC)
if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid &&
Z_OBJ_HANDLER_P(pz, get_properties) != NULL)) {
p = Z_OBJPROP_P(pz)->pListHead;
HashTable *props = Z_OBJPROP_P(pz);
if(!props) {
return;
}
p = props->pListHead;
while (p != NULL) {
pz = *(zval**)p->pData;
if (Z_TYPE_P(pz) != IS_ARRAY || Z_ARRVAL_P(pz) != &EG(symbol_table)) {
@@ -591,15 +625,17 @@ static void gc_collect_roots(TSRMLS_D)
gc_root_buffer *current = GC_G(roots).next;
while (current != &GC_G(roots)) {
if (current->handle && EG(objects_store).object_buckets) {
struct _store_object *obj = &EG(objects_store).object_buckets[current->handle].bucket.obj;
zval z;
if (current->handle) {
if (EG(objects_store).object_buckets) {
struct _store_object *obj = &EG(objects_store).object_buckets[current->handle].bucket.obj;
zval z;
GC_SET_ADDRESS(obj->buffered, NULL);
INIT_PZVAL(&z);
Z_OBJ_HANDLE(z) = current->handle;
Z_OBJ_HT(z) = current->u.handlers;
zobj_collect_white(&z TSRMLS_CC);
GC_SET_ADDRESS(obj->buffered, NULL);
INIT_PZVAL(&z);
Z_OBJ_HANDLE(z) = current->handle;
Z_OBJ_HT(z) = current->u.handlers;
zobj_collect_white(&z TSRMLS_CC);
}
} else {
GC_ZVAL_SET_ADDRESS(current->u.pz, NULL);
zval_collect_white(current->u.pz TSRMLS_CC);
+4 -1
View File
@@ -63,6 +63,9 @@ static void _zend_is_inconsistent(const HashTable *ht, const char *file, int lin
case HT_CLEANING:
zend_output_debug_string(1, "%s(%d) : ht=%p is being cleaned", file, line, ht);
break;
default:
zend_output_debug_string(1, "%s(%d) : ht=%p is inconsistent", file, line, ht);
break;
}
zend_bailout();
}
@@ -1455,7 +1458,7 @@ ZEND_API int zend_hash_compare(HashTable *ht1, HashTable *ht2, compare_func_t co
return 1;
}
} else { /* string index */
if (zend_hash_find(ht2, p1->arKey, p1->nKeyLength, &pData2)==FAILURE) {
if (zend_hash_quick_find(ht2, p1->arKey, p1->nKeyLength, p1->h, &pData2)==FAILURE) {
HASH_UNPROTECT_RECURSION(ht1);
HASH_UNPROTECT_RECURSION(ht2);
return 1;
+4 -4
View File
@@ -312,7 +312,7 @@ END_EXTERN_C()
} \
if (*tmp >= '0' && *tmp <= '9') { /* possibly a numeric index */ \
const char *end = key + length - 1; \
long idx; \
ulong idx; \
\
if ((*end != '\0') /* not a null terminated string */ \
|| (*tmp == '0' && length > 2) /* numbers with leading zeros */ \
@@ -328,11 +328,11 @@ END_EXTERN_C()
} \
if (tmp == end) { \
if (*key == '-') { \
idx = -idx; \
if (idx > 0) { /* overflow */ \
if (idx-1 > LONG_MAX) { /* overflow */ \
break; \
} \
} else if (idx < 0) { /* overflow */ \
idx = (ulong)(-(long)idx); \
} else if (idx > LONG_MAX) { /* overflow */ \
break; \
} \
return func; \
+18 -1
View File
@@ -304,7 +304,7 @@ statement:
;
section_string_or_value:
var_string_list { $$ = $1; }
var_string_list_section { $$ = $1; }
| /* empty */ { zend_ini_init_string(&$$); }
;
@@ -326,6 +326,15 @@ encapsed_list:
| /* empty */ { zend_ini_init_string(&$$); }
;
var_string_list_section:
cfg_var_ref { $$ = $1; }
| constant_literal { $$ = $1; }
| '"' encapsed_list '"' { $$ = $2; }
| var_string_list_section cfg_var_ref { zend_ini_add_string(&$$, &$1, &$2); free(Z_STRVAL($2)); }
| var_string_list_section constant_literal { zend_ini_add_string(&$$, &$1, &$2); free(Z_STRVAL($2)); }
| var_string_list_section '"' encapsed_list '"' { zend_ini_add_string(&$$, &$1, &$3); free(Z_STRVAL($3)); }
;
var_string_list:
cfg_var_ref { $$ = $1; }
| constant_string { $$ = $1; }
@@ -348,6 +357,14 @@ cfg_var_ref:
TC_DOLLAR_CURLY TC_VARNAME '}' { zend_ini_get_var(&$$, &$2 TSRMLS_CC); free(Z_STRVAL($2)); }
;
constant_literal:
TC_CONSTANT { $$ = $1; }
| TC_RAW { $$ = $1; /*printf("TC_RAW: '%s'\n", Z_STRVAL($1));*/ }
| TC_NUMBER { $$ = $1; /*printf("TC_NUMBER: '%s'\n", Z_STRVAL($1));*/ }
| TC_STRING { $$ = $1; /*printf("TC_STRING: '%s'\n", Z_STRVAL($1));*/ }
| TC_WHITESPACE { $$ = $1; /*printf("TC_WHITESPACE: '%s'\n", Z_STRVAL($1));*/ }
;
constant_string:
TC_CONSTANT { zend_ini_get_constant(&$$, &$1 TSRMLS_CC); }
| TC_RAW { $$ = $1; /*printf("TC_RAW: '%s'\n", Z_STRVAL($1));*/ }
+1474 -1466
View File
File diff suppressed because it is too large. Load diff
+2 -2
View File
@@ -315,7 +315,7 @@ restart:
if (YYCURSOR >= YYLIMIT) {
if (YYSTATE == STATE(ST_VALUE) || YYSTATE == STATE(ST_RAW)) {
BEGIN(INITIAL);
return 0;
return END_OF_LINE;
}
return 0;
}
@@ -344,7 +344,7 @@ DOLLAR_CURLY "${"
SECTION_RAW_CHARS [^\]\n\r]
SINGLE_QUOTED_CHARS [^']
RAW_VALUE_CHARS [^\n\r;]
RAW_VALUE_CHARS [^\n\r;\000]
LITERAL_DOLLAR ("$"([^{\000]|("\\"{ANY_CHAR})))
VALUE_CHARS ([^$= \t\n\r;&|~()!"'\000]|{LITERAL_DOLLAR})
+1 -1
View File
@@ -1,4 +1,4 @@
/* Generated by re2c 0.13.5 on Sun Feb 7 13:25:37 2010 */
/* Generated by re2c 0.13.5 on Sun Aug 1 12:07:43 2010 */
#line 3 "Zend/zend_ini_scanner_defs.h"
enum YYCONDTYPE {
File diff suppressed because it is too large. Load diff
+19 -3
View File
@@ -139,8 +139,10 @@ static void yy_pop_state(TSRMLS_D)
static void yy_scan_buffer(char *str, unsigned int len TSRMLS_DC)
{
YYCURSOR = (YYCTYPE*)str;
SCNG(yy_start) = YYCURSOR;
YYLIMIT = YYCURSOR + len;
if (!SCNG(yy_start)) {
SCNG(yy_start) = YYCURSOR;
}
}
void startup_scanner(TSRMLS_D)
@@ -241,7 +243,14 @@ ZEND_API void zend_destroy_file_handle(zend_file_handle *file_handle TSRMLS_DC)
ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC)
{
char *file_path = NULL, *buf;
size_t size;
size_t size, offset = 0;
/* The shebang line was read, get the current position to obtain the buffer start */
if (CG(start_lineno) == 2 && file_handle->type == ZEND_HANDLE_FP && file_handle->handle.fp) {
if ((offset = ftell(file_handle->handle.fp)) == -1) {
offset = 0;
}
}
if (zend_stream_fixup(file_handle, &buf, &size TSRMLS_CC) == FAILURE) {
return FAILURE;
@@ -257,6 +266,7 @@ ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC)
/* Reset the scanner for scanning the new file */
SCNG(yy_in) = file_handle;
SCNG(yy_start) = NULL;
if (size != -1) {
#ifdef ZEND_MULTIBYTE
@@ -274,10 +284,15 @@ ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC)
SCNG(script_filtered_size) = SCNG(script_org_size);
} else {
SCNG(input_filter)(&SCNG(script_filtered), &SCNG(script_filtered_size), SCNG(script_org), SCNG(script_org_size) TSRMLS_CC);
if (SCNG(script_filtered) == NULL) {
zend_error_noreturn(E_COMPILE_ERROR, "Could not convert the script from the detected "
"encoding \"%s\" to a compatible encoding", LANG_SCNG(script_encoding)->name);
}
}
SCNG(yy_start) = SCNG(script_filtered) - offset;
yy_scan_buffer((char *)SCNG(script_filtered), SCNG(script_filtered_size) TSRMLS_CC);
#else /* !ZEND_MULTIBYTE */
SCNG(yy_start) = buf - offset;
yy_scan_buffer(buf, size TSRMLS_CC);
#endif /* ZEND_MULTIBYTE */
} else {
@@ -413,6 +428,7 @@ ZEND_API int zend_prepare_string_for_scanning(zval *str, char *filename TSRMLS_D
memset(str->value.str.val + str->value.str.len, 0, ZEND_MMAP_AHEAD);
SCNG(yy_in)=NULL;
SCNG(yy_start) = NULL;
#ifdef ZEND_MULTIBYTE
SCNG(script_org) = (unsigned char *)estrdup(str->value.str.val);
+1 -1
View File
@@ -1,4 +1,4 @@
/* Generated by re2c 0.13.5 on Mon Jan 11 14:20:20 2010 */
/* Generated by re2c 0.13.5 on Tue Jun 29 08:18:52 2010 */
#line 3 "Zend/zend_language_scanner_defs.h"
enum YYCONDTYPE {
+45 -11
View File
@@ -340,13 +340,16 @@ zval *zend_std_read_property(zval *object, zval *member, int type TSRMLS_DC) /*
property_info = zend_get_property_info(zobj->ce, member, (zobj->ce->__get != NULL) TSRMLS_CC);
if (!property_info || zend_hash_quick_find(zobj->properties, property_info->name, property_info->name_length+1, property_info->h, (void **) &retval) == FAILURE) {
zend_guard *guard;
zend_guard *guard = NULL;
if (zobj->ce->__get &&
zend_get_property_guard(zobj, property_info, member, &guard) == SUCCESS &&
!guard->in_get) {
/* have getter - try with it! */
Z_ADDREF_P(object);
if (PZVAL_IS_REF(object)) {
SEPARATE_ZVAL(&object);
}
guard->in_get = 1; /* prevent circular getting */
rv = zend_std_call_getter(object, member TSRMLS_CC);
guard->in_get = 0;
@@ -373,6 +376,15 @@ zval *zend_std_read_property(zval *object, zval *member, int type TSRMLS_DC) /*
}
zval_ptr_dtor(&object);
} else {
if (zobj->ce->__get && guard && guard->in_get == 1) {
if (Z_STRVAL_P(member)[0] == '\0') {
if (Z_STRLEN_P(member) == 0) {
zend_error(E_ERROR, "Cannot access empty property");
} else {
zend_error(E_ERROR, "Cannot access property started with '\\0'");
}
}
}
if (!silent) {
zend_error(E_NOTICE,"Undefined property: %s::$%s", zobj->ce->name, Z_STRVAL_P(member));
}
@@ -436,22 +448,22 @@ static void zend_std_write_property(zval *object, zval *member, zval *value TSRM
}
}
} else {
int setter_done = 0;
zend_guard *guard;
zend_guard *guard = NULL;
if (zobj->ce->__set &&
zend_get_property_guard(zobj, property_info, member, &guard) == SUCCESS &&
!guard->in_set) {
Z_ADDREF_P(object);
if (PZVAL_IS_REF(object)) {
SEPARATE_ZVAL(&object);
}
guard->in_set = 1; /* prevent circular setting */
if (zend_std_call_setter(object, member, value TSRMLS_CC) != SUCCESS) {
/* for now, just ignore it - __set should take care of warnings, etc. */
}
setter_done = 1;
guard->in_set = 0;
zval_ptr_dtor(&object);
}
if (!setter_done && property_info) {
} else if (property_info) {
zval **foo;
/* if we assign referenced variable, we should separate it */
@@ -460,6 +472,14 @@ static void zend_std_write_property(zval *object, zval *member, zval *value TSRM
SEPARATE_ZVAL(&value);
}
zend_hash_quick_update(zobj->properties, property_info->name, property_info->name_length+1, property_info->h, &value, sizeof(zval *), (void **) &foo);
} else if (zobj->ce->__set && guard && guard->in_set == 1) {
if (Z_STRVAL_P(member)[0] == '\0') {
if (Z_STRLEN_P(member) == 0) {
zend_error(E_ERROR, "Cannot access empty property");
} else {
zend_error(E_ERROR, "Cannot access property started with '\\0'");
}
}
}
}
@@ -619,17 +639,28 @@ static void zend_std_unset_property(zval *object, zval *member TSRMLS_DC) /* {{{
property_info = zend_get_property_info(zobj->ce, member, (zobj->ce->__unset != NULL) TSRMLS_CC);
if (!property_info || zend_hash_quick_del(zobj->properties, property_info->name, property_info->name_length+1, property_info->h) == FAILURE) {
zend_guard *guard;
zend_guard *guard = NULL;
if (zobj->ce->__unset &&
zend_get_property_guard(zobj, property_info, member, &guard) == SUCCESS &&
!guard->in_unset) {
/* have unseter - try with it! */
Z_ADDREF_P(object);
if (PZVAL_IS_REF(object)) {
SEPARATE_ZVAL(&object);
}
guard->in_unset = 1; /* prevent circular unsetting */
zend_std_call_unsetter(object, member TSRMLS_CC);
guard->in_unset = 0;
zval_ptr_dtor(&object);
} else if (zobj->ce->__unset && guard && guard->in_unset == 1) {
if (Z_STRVAL_P(member)[0] == '\0') {
if (Z_STRLEN_P(member) == 0) {
zend_error(E_ERROR, "Cannot access empty property");
} else {
zend_error(E_ERROR, "Cannot access property started with '\\0'");
}
}
}
}
@@ -945,7 +976,7 @@ ZEND_API zend_function *zend_std_get_static_method(zend_class_entry *ce, char *f
/* Only change the method to the constructor if the constructor isn't called __construct
* we check for __ so we can be binary safe for lowering, we should use ZEND_CONSTRUCTOR_FUNC_NAME
*/
if (!memcmp(lc_class_name, function_name_strval, function_name_strlen) && memcmp(ce->constructor->common.function_name, "__", sizeof("__") - 1)) {
if (!memcmp(lc_class_name, lc_function_name, function_name_strlen) && memcmp(ce->constructor->common.function_name, "__", sizeof("__") - 1)) {
fbc = ce->constructor;
}
efree(lc_class_name);
@@ -953,13 +984,13 @@ ZEND_API zend_function *zend_std_get_static_method(zend_class_entry *ce, char *f
if (!fbc && zend_hash_find(&ce->function_table, lc_function_name, function_name_strlen+1, (void **) &fbc)==FAILURE) {
efree(lc_function_name);
if (ce->__callstatic) {
return zend_get_user_callstatic_function(ce, function_name_strval, function_name_strlen);
} else if (ce->__call &&
if (ce->__call &&
EG(This) &&
Z_OBJ_HT_P(EG(This))->get_class_entry &&
instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) {
return zend_get_user_call_function(ce, function_name_strval, function_name_strlen);
} else if (ce->__callstatic) {
return zend_get_user_callstatic_function(ce, function_name_strval, function_name_strlen);
} else {
return NULL;
}
@@ -1144,6 +1175,9 @@ static int zend_std_has_property(zval *object, zval *member, int has_set_exists
/* have issetter - try with it! */
Z_ADDREF_P(object);
if (PZVAL_IS_REF(object)) {
SEPARATE_ZVAL(&object);
}
guard->in_isset = 1; /* prevent circular getting */
rv = zend_std_call_issetter(object, member TSRMLS_CC);
if (rv) {
+17 -5
View File
@@ -52,6 +52,7 @@ ZEND_API void zend_objects_destroy_object(zend_object *object, zend_object_handl
zend_function *destructor = object ? object->ce->destructor : NULL;
if (destructor) {
zval *old_exception;
zval *obj;
zend_object_store_bucket *obj_bucket;
@@ -99,12 +100,23 @@ ZEND_API void zend_objects_destroy_object(zend_object *object, zend_object_handl
* For example, if an exception was thrown in a function and when the function's
* local variable destruction results in a destructor being called.
*/
if (EG(exception) && Z_OBJ_HANDLE_P(EG(exception)) == handle) {
zend_error(E_ERROR, "Attempt to destruct pending exception");
old_exception = NULL;
if (EG(exception)) {
if (Z_OBJ_HANDLE_P(EG(exception)) == handle) {
zend_error(E_ERROR, "Attempt to destruct pending exception");
} else {
old_exception = EG(exception);
EG(exception) = NULL;
}
}
zend_exception_save(TSRMLS_C);
zend_call_method_with_0_params(&obj, object->ce, &destructor, ZEND_DESTRUCTOR_FUNC_NAME, NULL);
zend_exception_restore(TSRMLS_C);
if (old_exception) {
if (EG(exception)) {
zend_exception_set_previous(EG(exception), old_exception TSRMLS_CC);
} else {
EG(exception) = old_exception;
}
}
zval_ptr_dtor(&obj);
}
}
@@ -134,7 +146,7 @@ ZEND_API zend_object *zend_objects_get_address(const zval *zobject TSRMLS_DC)
ZEND_API void zend_objects_clone_members(zend_object *new_object, zend_object_value new_obj_val, zend_object *old_object, zend_object_handle handle TSRMLS_DC)
{
zend_hash_copy(new_object->properties, old_object->properties, (copy_ctor_func_t) zval_add_ref, (void *) NULL /* Not used anymore */, sizeof(zval *));
zend_hash_copy(new_object->properties, old_object->properties, zval_copy_property_ctor(old_object->ce), (void *) NULL /* Not used anymore */, sizeof(zval *));
if (old_object->ce->clone) {
zval *new_obj;
+4 -1
View File
@@ -159,7 +159,10 @@ ZEND_API int zend_cleanup_class_data(zend_class_entry **pce TSRMLS_DC)
/* Note that only run-time accessed data need to be cleaned up, pre-defined data can
not contain objects and thus are not probelmatic */
zend_hash_apply(&(*pce)->function_table, (apply_func_t) zend_cleanup_function_data_full TSRMLS_CC);
(*pce)->static_members = NULL;
if ((*pce)->static_members) {
zend_hash_clean((*pce)->static_members);
(*pce)->static_members = NULL;
}
} else if (CE_STATIC_MEMBERS(*pce)) {
zend_hash_destroy(CE_STATIC_MEMBERS(*pce));
FREE_HASHTABLE(CE_STATIC_MEMBERS(*pce));
+30 -8
View File
@@ -30,6 +30,7 @@
#include "zend_multiply.h"
#include "zend_strtod.h"
#include "zend_exceptions.h"
#include "zend_closures.h"
#define LONG_SIGN_MASK (1L << (8*sizeof(long)-1))
@@ -646,7 +647,14 @@ ZEND_API void convert_to_array(zval *op) /* {{{ */
ALLOC_HASHTABLE(ht);
zend_hash_init(ht, 0, NULL, ZVAL_PTR_DTOR, 0);
if (Z_OBJ_HT_P(op)->get_properties) {
if (Z_OBJCE_P(op) == zend_ce_closure) {
convert_scalar_to_array(op, IS_ARRAY TSRMLS_CC);
if (Z_TYPE_P(op) == IS_ARRAY) {
zend_hash_destroy(ht);
FREE_HASHTABLE(ht);
return;
}
} else if (Z_OBJ_HT_P(op)->get_properties) {
HashTable *obj_ht = Z_OBJ_HT_P(op)->get_properties(op TSRMLS_CC);
if (obj_ht) {
zend_hash_copy(ht, obj_ht, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
@@ -965,8 +973,10 @@ ZEND_API int div_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ *
ZEND_API int mod_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
zendi_convert_to_long(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_long(op2, op2_copy, result);
if (Z_LVAL_P(op2) == 0) {
@@ -981,7 +991,7 @@ ZEND_API int mod_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ *
return SUCCESS;
}
ZVAL_LONG(result, Z_LVAL_P(op1) % Z_LVAL_P(op2));
ZVAL_LONG(result, op1_lval % Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
@@ -989,10 +999,12 @@ ZEND_API int mod_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ *
ZEND_API int boolean_xor_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
zendi_convert_to_boolean(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_boolean(op2, op2_copy, result);
ZVAL_BOOL(result, Z_LVAL_P(op1) ^ Z_LVAL_P(op2));
ZVAL_BOOL(result, op1_lval ^ Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
@@ -1038,6 +1050,7 @@ ZEND_API int bitwise_not_function(zval *result, zval *op1 TSRMLS_DC) /* {{{ */
ZEND_API int bitwise_or_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
if (Z_TYPE_P(op1) == IS_STRING && Z_TYPE_P(op2) == IS_STRING) {
zval *longer, *shorter;
@@ -1066,9 +1079,10 @@ ZEND_API int bitwise_or_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /
return SUCCESS;
}
zendi_convert_to_long(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_long(op2, op2_copy, result);
ZVAL_LONG(result, Z_LVAL_P(op1) | Z_LVAL_P(op2));
ZVAL_LONG(result, op1_lval | Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
@@ -1076,6 +1090,7 @@ ZEND_API int bitwise_or_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /
ZEND_API int bitwise_and_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
if (Z_TYPE_P(op1) == IS_STRING && Z_TYPE_P(op2) == IS_STRING) {
zval *longer, *shorter;
@@ -1106,9 +1121,10 @@ ZEND_API int bitwise_and_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
zendi_convert_to_long(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_long(op2, op2_copy, result);
ZVAL_LONG(result, Z_LVAL_P(op1) & Z_LVAL_P(op2));
ZVAL_LONG(result, op1_lval & Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
@@ -1116,6 +1132,7 @@ ZEND_API int bitwise_and_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
ZEND_API int bitwise_xor_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
if (Z_TYPE_P(op1) == IS_STRING && Z_TYPE_P(op2) == IS_STRING) {
zval *longer, *shorter;
@@ -1145,9 +1162,10 @@ ZEND_API int bitwise_xor_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
}
zendi_convert_to_long(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_long(op2, op2_copy, result);
ZVAL_LONG(result, Z_LVAL_P(op1) ^ Z_LVAL_P(op2));
ZVAL_LONG(result, op1_lval ^ Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
@@ -1155,10 +1173,12 @@ ZEND_API int bitwise_xor_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
ZEND_API int shift_left_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
zendi_convert_to_long(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_long(op2, op2_copy, result);
ZVAL_LONG(result, Z_LVAL_P(op1) << Z_LVAL_P(op2));
ZVAL_LONG(result, op1_lval << Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
@@ -1166,10 +1186,12 @@ ZEND_API int shift_left_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /
ZEND_API int shift_right_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
{
zval op1_copy, op2_copy;
long op1_lval;
zendi_convert_to_long(op1, op1_copy, result);
op1_lval = Z_LVAL_P(op1);
zendi_convert_to_long(op2, op2_copy, result);
ZVAL_LONG(result, Z_LVAL_P(op1) >> Z_LVAL_P(op2));
ZVAL_LONG(result, op1_lval >> Z_LVAL_P(op2));
return SUCCESS;
}
/* }}} */
Loaded 100 of 1025 files, more files were not shown because too many files have changed in this diff. Show more