Compare commits

...
Author SHA1 Message Date
SVN Migration a4b6eb9b18 This commit was manufactured by cvs2svn to create tag 'php_5_0_3RC2'. 2004-12-10 01:03:05 +00:00
Andi Gutmans fcde3b066e - 5.0.3RC2 2004-12-10 01:03:04 +00:00
Antony Dovgal 2cdc86e8b4 CS changes 2004-12-09 17:16:33 +00:00
Antony Dovgal cab8f40c2e MFH: fix segfault in session_module_name() when session.save_handler is empty 2004-12-09 14:17:34 +00:00
Pierre Joye 12374956d0 - fix the entry position, thx D 2004-12-09 10:30:14 +00:00
Pierre Joye 5efb3301b2 - MFH: #28598, attempt to restore MS Symbol ttf support 2004-12-09 10:11:11 +00:00
Pierre Joye cbdd728a8d - MFB: #30229, fixed imagerectangle used with alpha channel
- MFB: imagefill, always restore the alphablending mode
2004-12-09 09:19:59 +00:00
Derick Rethans 5a4d19abe6 - MFH: Fixed bug #31034 (Problem with non-existing iconv header file). (Derick) 2004-12-09 09:05:36 +00:00
Antony Dovgal 6cb74fb894 MFH: buffer overrun & debug printf() 2004-12-09 08:24:33 +00:00
Frank M. Kromann c40cb3fce6 MFB: Fix logic for file checking. Bug #31019 2004-12-08 18:58:25 +00:00
Joe Orton 4ba3d20c88 MFH: Fix VPATH build again. 2004-12-08 12:55:33 +00:00
foobar 7b5258ab93 MFH: Fix build. This was not supposed to halt configure if test fails. 2004-12-08 06:47:10 +00:00
Brad House 1d4d921a59 backport from head. compatability fix with libmonetra 4.2 and higher (still works with older releases too). 2004-12-08 03:08:39 +00:00
Dmitry Stogov 0d6c158620 Fixed crash in phpinfo() after graceful Apache restart. 2004-12-07 18:01:56 +00:00
Dmitry Stogov 74320cba7e Fixed bug #30928 (When Using WSDL, SoapServer doesn't handle private or protected properties) 2004-12-07 17:29:24 +00:00
Antony Dovgal 73346d2f76 MFH: fix leak in bcpowmod() 2004-12-07 17:07:16 +00:00
Derick Rethans 74b56b1258 - Tidy up NEWS a bit 2004-12-07 08:44:07 +00:00
Dmitry Stogov ac5f1552ff Fixed bug #30904 (segfault when recording soapclient into session). 2004-12-07 07:45:46 +00:00
Ilia Alshanetsky 93f65e2510 MFH: Fixed bug #30995 (snmp extension does not build with net-snmp 5.2). 2004-12-07 00:33:58 +00:00
Ilia Alshanetsky 4c4bfd3c9b MFH: Fixed bug #30990 (allow popen() on *NIX to accept 'b' flag). 2004-12-06 23:31:07 +00:00
Derick Rethans ea97c82b97 - MF43: Install the iconv extension headers to <installpath>/ext/iconv so that
external extensions can use them.
2004-12-06 20:38:55 +00:00
Ilia Alshanetsky a6e1c3616b MFB: revert. 2004-12-06 19:45:57 +00:00
Stanislav Malyshev e1dc8e60a4 fix startup - if startup did not succeed, do not continue with execution 2004-12-06 18:55:38 +00:00
Stanislav Malyshev cda0f6145f do not zero out peak - MM shutdown would do that 2004-12-06 18:52:52 +00:00
Stanislav Malyshev b700e7a9db port fix for #30998: Crash when user error handler returns false on amd64 2004-12-06 15:46:04 +00:00
Dmitry Stogov 763006984d Fixed bug #30922 (reflective functions crash PHP when interfaces extend themselves) 2004-12-06 11:53:00 +00:00
Stanislav Malyshev 9bea6b1fb0 if fetch called not from PHP function, ptr can be NULL 2004-12-06 08:57:55 +00:00
Georg Richter 135d118ce7 MFH: fixed windows compile errors 2004-12-06 05:15:36 +00:00
Holger Zimmermann 1b6665b0d9 Replaced static server variables by function call and configurable list at the Pi3Web server side. 2004-12-05 10:32:30 +00:00
Rob Richards 6f7b5eba99 BFN 2004-12-04 11:41:46 +00:00
Rob Richards ccf618e1dd MFH: Fixed bug #28817 (Var problem when extending domDocument). (Georg)
add test
2004-12-04 11:41:12 +00:00
SVN Migration f80035fb65 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-12-04 11:40:11 +00:00
Georg Richter 9c44d66034 fixed bug #30890 2004-12-04 09:03:36 +00:00
Georg Richter 6db67fe4ff MFH:
fix for bug #28817 (properties don't work in extended class)
	fix for bug #30890 (testsuite)
2004-12-04 09:01:34 +00:00
Antony Dovgal 125c9028a7 MFH: fix array_walk_recursive() so it doesn't reuse cached fci between calls
and add test for it
2004-12-03 17:51:17 +00:00
SVN Migration 53e61c7f1f This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-12-03 17:43:24 +00:00
Stefan Esser da02892d8c fix compile 2004-12-03 16:10:29 +00:00
Stefan Esser cd385539a3 MFH 2004-12-03 16:04:10 +00:00
Georg Richter a718d62f74 MFH: Fix for bug #30967 (properties in extended mysqli classes don't work) 2004-12-03 07:57:39 +00:00
SVN Migration 3931103064 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-12-03 07:56:20 +00:00
Ilia Alshanetsky 238393e58a MFH: Fixed bug #30962 (mssql returns space for NULL columns). 2004-12-03 02:26:36 +00:00
Antony Dovgal 3de8ff865a MFH: fix tests 2004-12-02 16:39:02 +00:00
Antony Dovgal 0cb5aa2d53 MFH: revert my last patch 2004-12-02 16:36:00 +00:00
Stefan Esser 89c61babec MFH 2004-12-02 01:04:34 +00:00
Stefan Esser c5d37e6879 MFH 2004-12-02 00:44:22 +00:00
Stefan Esser 9bce9725ce MFH 2004-12-01 22:56:20 +00:00
Stefan Esser fa13af4d59 MFH 2004-12-01 22:42:14 +00:00
Ilia Alshanetsky 916af07bc8 Removed extra space that causes problems for some compilers. 2004-12-01 18:51:41 +00:00
Dmitry Stogov 193bdf06d6 Fixed bug #30329 (Error Fetching http body, No Content-Length, connection closed or chunked data). 2004-12-01 18:22:24 +00:00
Dmitry Stogov a3d2a4da0c Port 443 is default for https, so we shouldn't put it into Host: 2004-12-01 17:33:19 +00:00
Dmitry Stogov a847d3a9dd Fixed bug #30359 (SOAP client requests have no port in "Host" field ). 2004-12-01 16:59:23 +00:00
Derick Rethans 618e5b21c3 - revert unwanted change 2004-12-01 15:11:51 +00:00
Derick Rethans 3bc9cc5d2d - Fixed MacOSX compilation (Patch by Christian) 2004-12-01 15:05:10 +00:00
Derick Rethans da1255b17f - And in Zend/ too. 2004-12-01 14:46:13 +00:00
Derick Rethans a2c4aeb659 - Roll back to -dev 2004-12-01 14:44:54 +00:00
Dmitry Stogov 239e693751 Fixed bug #29883 (isset gives invalid values on strings). 2004-12-01 14:01:58 +00:00
Derick Rethans 039dd23c03 - MF43: Update install instructions 2004-12-01 09:15:38 +00:00
Andi Gutmans 1d23c4d551 - Go with 5.0.3RC1 2004-11-30 01:39:18 +00:00
Derick Rethans 2082e22123 - MFH: Added testcase for bug #30695 2004-11-29 10:15:16 +00:00
SVN Migration 62f1637939 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-11-29 10:15:05 +00:00
Derick Rethans 96cae711b9 - MF43: Revert Joe's work around a bug in GCC patch as it breaks too many things. 2004-11-29 09:39:57 +00:00
Sergey Kartashoff 3886f88503 - MnoGoSearch extension updated to fix compilation issues with
mnogosearch-3.2.25+
2004-11-28 20:04:03 +00:00
Antony Dovgal d030269743 BFN 2004-11-28 17:13:49 +00:00
Antony Dovgal 61e2b771d4 MFH: fix #29954 (array_reduce segfaults when initial value is array) 2004-11-28 17:04:18 +00:00
Stefan Esser 2e9541bef5 MFH 2004-11-28 13:34:01 +00:00
Antony Dovgal 43b6cc62b1 MFH: fix #30314 2004-11-28 13:22:11 +00:00
Stefan Esser ab4bfa115c MFH 2004-11-28 12:44:42 +00:00
Ilia Alshanetsky 3a2fb113bc MFH: Improve offset check inside shmop_write(). 2004-11-27 18:18:09 +00:00
Marcus Boerger bdad6ef8c1 - Nowadays we drop fixes :-) 2004-11-27 10:14:20 +00:00
Zeev Suraski 59b098a525 Reverting get_method() signature change
@ Guys - I did my best to look for all of the changed places,
@ but I may have missed something.  If you remember other places
@ which were changed that I haven't reverted, please fix or let me know.
@ Also - Marcus, please take a look at SPL - as this particular
@ implementation took advantage of the signature change, the way I 'fixed'
@ it may very well be incorrect
2004-11-25 20:28:37 +00:00
Zeev Suraski a7cb6a8808 Reverting get_method() signature change 2004-11-25 20:26:48 +00:00
Ilia Alshanetsky 271e7df5eb MFH: Fixed compilation when PHP is built in separate directory. 2004-11-24 23:12:57 +00:00
Marcus Boerger 0a60e71454 - BFN 2004-11-24 20:00:52 +00:00
Marcus Boerger 4163964612 - MFH Bugfix #30856 2004-11-24 19:59:28 +00:00
SVN Migration 29cd249649 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-11-24 19:56:26 +00:00
Dmitry Stogov f444b875b0 Test was fixed. 2004-11-23 17:22:13 +00:00
Derick Rethans 9327ad7d07 - MFH: We need to install these headers too 2004-11-23 13:06:16 +00:00
Edin Kadribasic 74d23c256b MFH 2004-11-23 12:07:25 +00:00
Derick Rethans 68aff652b9 - MFH: export "php_iconv_string()" 2004-11-23 09:45:33 +00:00
Derick Rethans aa06288173 - MFH: Added testcase for bug #28599 2004-11-23 09:44:20 +00:00
SVN Migration 77c460b59f This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-11-23 09:40:09 +00:00
Andi Gutmans d09c0303b8 - Don't use that ZTS connection pooling code until decided what to do with
- this problem.
2004-11-22 21:46:49 +00:00
Frank M. Kromann 7064084418 MFH: Fix #30860 configure fails when tds is compiled as shared 2004-11-22 19:45:17 +00:00
Dmitry Stogov d605aa7846 Test was fixed. 2004-11-22 17:43:31 +00:00
Dmitry Stogov 36a5a19c48 Skip condition was fixed. 2004-11-22 15:15:31 +00:00
Dmitry Stogov 71f00b6ab2 Tests were fixed. 2004-11-22 15:14:14 +00:00
Rob Richards 3bdc15821f MFH: internal entities expanded if no default handler but cdata handler exists 2004-11-21 14:26:26 +00:00
Antony Dovgal 3222f1defb fix yet another typo 2004-11-21 13:35:50 +00:00
Antony Dovgal b65cff0f53 fix typo (bug #30857) 2004-11-21 13:34:02 +00:00
Stefan Esser 4e5296741d MFH 2004-11-20 20:16:27 +00:00
Rob Richards 7ec21cca55 MFH: fix crash when calling com methods
- due to change in Zend
2004-11-20 11:41:24 +00:00
Antony Dovgal acab9b33be BFN 2004-11-19 17:18:09 +00:00
Antony Dovgal bb7515902c MFH: fix bug #30587 (array_multisort doesn't separate zvals before changing them) 2004-11-19 16:57:06 +00:00
Rob Richards 8d3bd0f4f7 BFN 2004-11-18 20:17:08 +00:00
Rob Richards 40d8309354 MFH: Fixed bug #30061 (xml_set_start_namespace_decl_handler not called)
hopefully resolve a bunch of entity issues
2004-11-18 20:16:45 +00:00
Rob Richards 62f3ccdea9 MFH: prototype fixes (Jakub Vrána) 2004-11-18 19:55:00 +00:00
Rob Richards 77598e0382 BFN and re-order news 2004-11-18 18:28:03 +00:00
Rob Richards d67ee093e8 MFH: Fixed bug #30832 ("!" stripped off comments in xml parser)
reset sax->initialized flag when not using SAX2
2004-11-18 18:26:59 +00:00
Rob Richards 69644e9272 MFH: fix SAX2 handling to work with libxml 2.6.16 2004-11-18 16:36:34 +00:00
Antony Dovgal fbb708e211 MFH: run-test2 should be able to emulate POST & GET in the same time 2004-11-18 16:23:40 +00:00
Ilia Alshanetsky 797a132d51 MFH: Gracefully handle allocation failure. 2004-11-17 23:42:28 +00:00
Stanislav Malyshev 3241d7fc46 fix #30543 2004-11-17 12:39:52 +00:00
Dmitry Stogov a8a3ae8566 namespace was renamed 2004-11-17 06:19:12 +00:00
Edin Kadribasic f65691dc68 Fix build here too 2004-11-17 00:24:42 +00:00
Ilia Alshanetsky 91aaefe043 MFH: Fixed possible usage of un-initialized variable. 2004-11-16 21:04:27 +00:00
Dmitry Stogov e8cd732fb2 indentation fixed. 2004-11-16 13:51:32 +00:00
Dmitry Stogov 6a7ed50811 Fixed bug #30799 (SoapServer doesn't handle private or protected properties) 2004-11-16 13:07:27 +00:00
SVN Migration bacd5371f4 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-11-16 13:04:40 +00:00
Dmitry Stogov 95e9a21e31 Class mapping was implemented (Bug #29385 Soapserver always uses std class). 2004-11-16 12:13:40 +00:00
SVN Migration e1c0bcd35f This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-11-16 12:07:33 +00:00
Derick Rethans 34eb46c6b2 - Make this compile for the Mac again 2004-11-16 07:48:32 +00:00
Ilia Alshanetsky 67dcd65a57 MFH: Fixed bug #29801 (Set limit on the size of mmapable data). 2004-11-15 23:44:14 +00:00
Ilia Alshanetsky 00fa3587ba Fixed build. 2004-11-15 23:35:50 +00:00
Edin Kadribasic 044fba0b64 MFH 2004-11-15 23:29:42 +00:00
Frank M. Kromann 99041df380 Avoid renaming of sprintf to php_sprintf 2004-11-15 23:16:20 +00:00
Frank M. Kromann ee3f17d3ee Fix win32 build. 2004-11-15 23:14:40 +00:00
Frank M. Kromann 509eca4182 MFH: Adding most of the changes suggested in #30280. Mostly fix's for possible leaks. 2004-11-15 22:47:57 +00:00
Derick Rethans 6b97f4e98c - MFH: Fixed bug #30779 (Compile of Zend/zend_strtod.c fails on Sparc) 2004-11-15 19:26:57 +00:00
Sergey Kartashoff fcf9c0892d # Unix EOLs fixed 2004-11-15 19:07:35 +00:00
Sergey Kartashoff 3c1b0101ef # Copyright header & version info changed to PHP 5 standatd notice 2004-11-15 19:02:39 +00:00
Derick Rethans 7d5b5f3054 - Those are also fixed with the same commit. 2004-11-15 16:42:10 +00:00
Derick Rethans 7a379811d4 - Fixed bug #28599 (strtotime fails with zero base time). 2004-11-15 16:30:46 +00:00
Antony Dovgal 6749b09d8b MFH: fix CLI leaks when using malformed option string 2004-11-15 14:08:33 +00:00
Derick Rethans 1a1713a4c7 - MF4.3: Cleaned up some of the locale mess:
* all internal use of sprintf, snprintf and the like will always
    use the . as thousands seperator (if php.h is included only!).
  * echo, printf() and sprintf() always render locale-aware
  * added the %F modifier for non-locale aware rendering for floats
2004-11-15 13:41:41 +00:00
Sergey Kartashoff af05fce6b6 # Unix EOLs fixed 2004-11-14 19:30:16 +00:00
Sergey Kartashoff 985122db3b - More mnogosearch-3.2.23+ compatibility 2004-11-14 18:23:52 +00:00
Marcus Boerger 216a000ce3 BFN 2004-11-14 18:09:44 +00:00
Marcus Boerger 3f35f2252d MFH #30783 Apache crash when using ReflectionFunction::getStaticVariables()
MFH proto fixes
2004-11-14 18:07:15 +00:00
Antony Dovgal 480af61b74 MFH: fix #30780 (tidy segfaults on 'new tidyNode;') 2004-11-14 13:35:48 +00:00
Rob Richards f67d540a1b BFN 2004-11-13 14:33:59 +00:00
Rob Richards 2452c92c2b MFH: Fixed bug #30566 (attribute namespace URIs are inconsistent when parsing). 2004-11-13 14:33:25 +00:00
Rob Richards b6b00a822c support file:/// under windows again 2004-11-11 13:09:03 +00:00
Ard Biesheuvel 586f73b1ee MFH: fix return value of ibase_execute() 2004-11-11 12:29:34 +00:00
Dmitry Stogov 4bc6ac34ae Support for lists in non-WSDL mode was implemented
Support for "xsi:type" was improved
2004-11-11 09:16:36 +00:00
Antony Dovgal c32445a860 MFH: fix #30751 (phpinfo() shows the same ini path after reconfigure with --with-config-file-path) 2004-11-11 06:58:00 +00:00
Ilia Alshanetsky 0f04dff942 MFH: Fixed bug #30750 (Meaningful error message when upload directory is not
accessible).
2004-11-11 00:38:44 +00:00
Wez Furlong 70a7fced75 MFH: CloseHandle 2004-11-10 20:21:48 +00:00
Ilia Alshanetsky 47fff9a15d MFH: Fixed possible overflow. 2004-11-10 01:44:28 +00:00
Dmitry Stogov 50a4e4003a Fixed bug #29211 (SoapClient doesn't request wsdl through proxy). (Rob) 2004-11-09 08:13:04 +00:00
Ilia Alshanetsky e0ffe2f109 MFH: Fixed crash inside cpdf_setdash() if called before page init. 2004-11-09 00:44:29 +00:00
Ilia Alshanetsky fa5fbd0a0d MFH: Fixed possible crash on fstat() failure. 2004-11-08 04:54:58 +00:00
Derick Rethans aac98f3eba - Fix for bug #30367, #30490 and possibly #30011. 2004-11-05 15:08:11 +00:00
Antony Dovgal 6f35c85c19 MFH: fix build (hm. looks like nobody noticed that..) 2004-11-05 12:31:58 +00:00
Marcus Boerger 5fd210de89 MFH Bug #30627 2004-11-04 20:15:38 +00:00
Dmitry Stogov 49c5edcb9f Fixed bug #30685 (Malformed SOAPClient http header reequest). 2004-11-04 15:29:54 +00:00
Edin Kadribasic 07c6cb2a5b MFH 2004-11-04 02:42:14 +00:00
Edin Kadribasic 9891d3e03d MFH: zend_strtod compilation on windows 2004-11-04 02:22:10 +00:00
Moriyoshi Koizumi c3c311943c - MFH: Add entry for zend_strtod.c in belief that this is still active. 2004-11-04 00:15:11 +00:00
Derick Rethans d0fd3bf62e - MFH: Fixed bug #30630: Added a BSD based strtod function that is
locale-independent. (PHP part)
2004-11-03 23:27:28 +00:00
Derick Rethans 90546a871f - MFH: Fixed bug #30630: Added a BSD based strtod function that is
locale-independent.
2004-11-03 23:14:32 +00:00
SVN Migration f2d992c76f This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-11-03 23:13:33 +00:00
Andrey Hristov 36b416f514 MFH 2004-11-02 17:25:14 +00:00
Ilia Alshanetsky 03ba78106d Bug fixing news. 2004-11-02 16:42:46 +00:00
Ilia Alshanetsky c7b537e2c3 Fixed bug #30658 (Ensure that temporary files created by GD are removed). 2004-11-02 16:41:26 +00:00
Sebastian Bergmann 523d3c122f MFH: Patch by Joe Orton <jorton@redhat.com>. 2004-11-02 13:19:48 +00:00
Ilia Alshanetsky e79de46f3c MFH: Fixed open_basedir & safe_mode bypass inside readlink() function. 2004-11-02 00:37:55 +00:00
Georg Richter 66a74b4c68 Added default multi resultset support for mysqli_connect (#30645) 2004-11-01 09:52:04 +00:00
Georg Richter fd0e9cc044 fixed error handling in mysqli_multi_query 2004-11-01 07:59:05 +00:00
Georg Richter f2dc3a258d MFH:
Fixed tests for empty dates (see http://bugs.mysql.com/?id=6058)
Fixed memleak in mysqli_stmt_bind_result
Fixed error handling for mysqli_multi_query
2004-11-01 07:57:46 +00:00
Ilia Alshanetsky 6330a6078d Fixed bug #30613 (Prevent infinite recursion in url redirection). 2004-11-01 04:52:51 +00:00
Marcus Boerger ce726fa710 - Fix arginfo 2004-10-31 15:43:06 +00:00
Sebastian Bergmann 0b640b29d7 MFH: Invokation -> Invocation 2004-10-31 10:20:01 +00:00
Marcus Boerger f0e8e0eae8 - Fix (readd function name which got lost during earlier comit) 2004-10-30 20:22:51 +00:00
Marcus Boerger ef3ed0e4d4 BFN 2004-10-30 19:56:34 +00:00
Marcus Boerger 6317956d02 MFH 2004-10-30 19:53:44 +00:00
Marcus Boerger b1e05a7b4f Bump api after latest changes 2004-10-30 19:26:04 +00:00
Marcus Boerger 65a2433793 MFH 2004-10-30 19:21:59 +00:00
Marcus Boerger a5a29a86df MFH change zend_object_handlers->get_method() 2004-10-30 19:16:39 +00:00
Marcus Boerger 7226e7077d MFH 2004-10-30 14:35:01 +00:00
Marcus Boerger 00c9bd1a33 MFH Fix protos 2004-10-30 10:46:24 +00:00
Andi Gutmans 8a340b1572 - [PATCH] Bug fix for #29770, but for PHP 4.3.9 (Vladimir Zidar) 2004-10-29 00:37:51 +00:00
Greg Beaver 4b03f9f172 sync with pear-core 2004-10-28 19:33:23 +00:00
Greg Beaver 167c1675b9 PEAR => 1.3.3 2004-10-28 19:31:07 +00:00
Antony Dovgal 5ddec61e2d fix Win32 & Netware build 2004-10-28 05:05:39 +00:00
Andi Gutmans 77e96aec61 - MFH 2004-10-27 18:15:53 +00:00
Antony Dovgal 9b6a953c91 BFN 2004-10-27 12:05:14 +00:00
Antony Dovgal 61e90440ce MFH: fix bug #30388 (rename across filesystems loses ownership and permission info) 2004-10-27 11:59:48 +00:00
Wez Furlong 0faac783e9 Fix possible crash; patch by Kamesh Jayachandran 2004-10-27 11:07:53 +00:00
Andrey Hristov 95b0546558 news entry 2004-10-26 23:34:43 +00:00
Andi Gutmans e5f62e61e6 - MFH 2004-10-26 23:25:34 +00:00
Ilia Alshanetsky 0484413b86 MFH: Fixed bug #30572 (crash when comparing SimpleXML attribute to a boolean). 2004-10-26 22:40:51 +00:00
Wez Furlong 59cb64f707 BFN 2004-10-26 09:32:01 +00:00
Wez Furlong af9a8dfaa3 Fix for Bug #29418 (double free when openssl_csr_new fails).
Also hook up MSHUTDOWN function which appears to have never been enabled.

Patch by Kamesh Jayachandran
2004-10-26 09:28:34 +00:00
Greg Beaver 01ba76a2ed sync with PEAR_1_3 branch of pear-core 2004-10-25 17:14:34 +00:00
Greg Beaver cd067e641a update for PEAR 1.3.2 2004-10-25 17:06:12 +00:00
Greg Beaver 1228570437 pass in first parameter to work with go-pear 0.5.0 "local" option 2004-10-25 04:11:40 +00:00
Antony Dovgal c6b00a1223 MFH: commit fixes by <mikael dot suvi at trigger dot ee>
(segfaults under heavy load)
2004-10-23 09:34:17 +00:00
Edin Kadribasic 998a9f4438 Revert Linux LFS patch 2004-10-22 10:47:35 +00:00
Edin Kadribasic 3959fe2470 BFN 2004-10-22 00:03:17 +00:00
Edin Kadribasic db5037537b MFB: Linux LFS support, fixes 27792 2004-10-21 23:57:37 +00:00
Joe Orton 88c5b75698 MFH: Fix case where php_handle_aborted_connection was called
outside a try/end_try block (#25570).
2004-10-21 08:22:58 +00:00
Andi Gutmans c6e0f60774 - Fix bug #30395 (Apache Child Segmentation fault in specific PHP-Code) 2004-10-21 00:47:11 +00:00
Andi Gutmans 1cae37c3da - MFH 2004-10-20 19:33:35 +00:00
Georg Richter 6ab8a6705d Minor fix for mysqli_connect: checking socket_len for NULL Values
(Thx to Paul DuBois)
2004-10-19 05:17:26 +00:00
Ilia Alshanetsky 8c13a77e97 MFH: Fixed bug #30475 (curl_getinfo() may crash in some situations). 2004-10-18 22:42:16 +00:00
Antony Dovgal f1df31a3fb BFN 2004-10-18 15:17:04 +00:00
Antony Dovgal 750646d822 MFH: fix bug #30442 ( segmentation fault when parsing ?getvariable[][ ) 2004-10-18 15:07:06 +00:00
Anantha Kesari H Y 3f4cf40c45 removing a call to php_output_activate in php_module_startup(Fix for bug#30397) 2004-10-18 10:36:35 +00:00
Derick Rethans f941d0aeb0 - Revert patch until it is discussed 2004-10-18 06:04:10 +00:00
Anantha Kesari H Y 331c9a83a3 Fix for Bug #30397 2004-10-16 10:34:59 +00:00
Anantha Kesari H Y cf476b6a51 Fix for 30457 2004-10-16 09:48:23 +00:00
Marcus Boerger eacce9faca BFN 2004-10-12 22:35:38 +00:00
Marcus Boerger 9b68fae9c9 BFN 2004-10-12 22:23:48 +00:00
Marcus Boerger c981347ffb MFH Bug #30381 2004-10-12 22:22:06 +00:00
Marcus Boerger 8360ce27aa MFH Fix visibility of get_class_vars() and get_class_methods() 2004-10-12 11:03:35 +00:00
Marcus Boerger 0bcb369eac MFH (add missing check) 2004-10-12 09:16:17 +00:00
Marcus Boerger 0c7f673a91 -MFH Fix set_exception_handler() 2004-10-12 09:14:55 +00:00
Ilia Alshanetsky 02a2e47986 MFH: Fixed bug #30362 (stream_get_line() not handling end string correctly) 2004-10-11 18:33:00 +00:00
Ilia Alshanetsky 3657fef77c MFH: Fixed bug #30375 (cal_info() does not work without a parameter). 2004-10-11 06:40:20 +00:00
Wez Furlong d75ba00e90 BFN 2004-10-11 01:43:40 +00:00
Wez Furlong 1d31caf032 MFH: return value fix (#30387 again) 2004-10-11 01:41:23 +00:00
Wez Furlong a50b0e717f MFH: Fix #30387: wrong flag used for async connection 2004-10-11 01:34:26 +00:00
Sebastian Bergmann b2ccce05e3 MFH: Add *.gcda and *.gcno (from gcc -fprofile-{use|generate}) to .cvsignore. 2004-10-10 16:15:52 +00:00
Antony Dovgal 45a4e123e7 fix possible segfault 2004-10-10 15:05:52 +00:00
Antony Dovgal 8f16f600d5 MFH: prevent deadlocks when re-using previously established persistent connection 2004-10-10 10:55:48 +00:00
Wez Furlong 055d1c2134 MFH: dotnet init fixes 2004-10-09 13:10:37 +00:00
Wez Furlong e188ea9d39 MFH: fix for crash bug 2004-10-09 13:08:49 +00:00
Marcus Boerger 11031593f3 MFH speling 2004-10-08 19:03:53 +00:00
Christian Stocker eca839ae19 MFH
Fixed bug #27183 (Userland stream wrapper segfaults on stream_write).
2004-10-08 14:53:39 +00:00
Moriyoshi Koizumi ac70367d73 - BFN 2004-10-08 14:46:47 +00:00
Moriyoshi Koizumi d5830722a5 - MFH: Sync with the latest codebase (fixes bug #28220). 2004-10-08 14:45:47 +00:00
SVN Migration 82dae9d9be This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-10-08 14:40:47 +00:00
Moriyoshi Koizumi e817baae1e - MFH(r-1.53): Avoid doubly symbol definition. Codes in the removed file has
never been used anywhere.
2004-10-08 14:24:29 +00:00
Ilia Alshanetsky 7c3962f79d MFH: Fixed bug #30356 (str_ireplace() does not work on all strings). 2004-10-07 23:11:20 +00:00
Marcus Boerger 2016ad5441 BFN 2004-10-06 21:32:12 +00:00
Marcus Boerger 67c833661e - MFH (synch after func name change) 2004-10-06 21:27:25 +00:00
Marcus Boerger 8b765c3c44 - MFH Fix Bug #30344 2004-10-06 21:25:37 +00:00
Ilia Alshanetsky 2daa88cd48 Possible fix for bug #29764 2004-10-06 00:12:04 +00:00
Ilia Alshanetsky 32617aea68 MFH: Fixed bug #30027 (Possible crash inside ftp_get()). 2004-10-05 23:53:14 +00:00
Marcus Boerger 69d71f67d2 BFN 2004-10-05 18:45:01 +00:00
Dmitry Stogov f779b01bca Fixed bug #30175 (SOAP results aren't parsed correctly) 2004-10-05 15:58:28 +00:00
Ilia Alshanetsky 0036a3e4da MFH: Fixed bug #30281 (Prevent non-wbmp images from being detected as such) 2004-10-04 20:43:21 +00:00
Marcus Boerger b2f560dc94 MFH 2004-10-04 17:54:13 +00:00
SVN Migration 501a4edf49 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-10-04 17:53:56 +00:00
Marcus Boerger c896d7d6d0 - MFH Add new test 2004-10-04 17:31:37 +00:00
SVN Migration 0285963ec3 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-10-04 17:30:54 +00:00
Marcus Boerger 84a00322eb BFN 2004-10-04 09:04:00 +00:00
Marcus Boerger 5dbe92d8a7 MFH 2004-10-04 09:03:10 +00:00
SVN Migration c2e2a30169 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-10-04 08:58:48 +00:00
Ilia Alshanetsky dee4566360 Test case for bug #30085 2004-10-04 02:46:03 +00:00
Marcus Boerger 900df55818 - Add new tests 2004-10-02 14:33:37 +00:00
SVN Migration d0ff60e95f This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-10-02 14:22:53 +00:00
Rasmus Lerdorf 98aa5b6eb2 Not sure when this BC breaking change snuck in, but the output method
didn't take an argument before and this compression argument is documented
to be optional but in the code it wasn't.  This patch fixes the BC break
by making the compression argument optional.
2004-10-01 19:23:40 +00:00
Sebastian Bergmann 4f92686415 MFH: Fugbix typo. 2004-10-01 10:36:50 +00:00
Ilia Alshanetsky a2f06a9a3c Added skip condition for PHP 5.0 2004-09-30 21:54:28 +00:00
Andi Gutmans 942c837e9f - MFH 2004-09-30 18:36:21 +00:00
Antony Dovgal 890b377094 BFN 2004-09-30 15:00:57 +00:00
Antony Dovgal fb5c9e76fc fix error message 2004-09-30 14:20:22 +00:00
Antony Dovgal d5f88b12c0 MFH: fix segfaults and bug #30282 and suppress compile warnings 2004-09-30 12:37:35 +00:00
Ilia Alshanetsky 7dd408c7e5 MFH: Fixed bug #30276 (Possible crash in ctype_digit on large numbers). 2004-09-30 01:23:34 +00:00
Marcus Boerger b00c9f4501 MFH 2004-09-29 20:16:03 +00:00
Antony Dovgal e81f5ce137 MFH: fix bug #29652 2004-09-29 06:43:29 +00:00
Frank M. Kromann 6081651c65 MFH: Fix compilation 2004-09-28 18:39:22 +00:00
Ilia Alshanetsky cbfa37cfad MFH: Fixed bug #30224 (Sybase date strings are sometimes not null
terminated).
2004-09-28 14:07:59 +00:00
Wez Furlong 797cda2555 MFH: select usage fix 2004-09-28 09:30:20 +00:00
Wez Furlong a540196a41 MFH: Fix for Bug #24189: possibly unsafe select(2) usage. 2004-09-28 09:13:38 +00:00
Marcus Boerger c33bcdda04 MFH fix several property handling issues 2004-09-27 22:28:58 +00:00
Marcus Boerger d85e4ebcc2 MFH parameter description 2004-09-27 22:28:19 +00:00
Marcus Boerger 3b1d4b09da MFH Add new tests 2004-09-27 22:27:54 +00:00
SVN Migration 36280edc99 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-09-27 22:23:32 +00:00
Edin Kadribasic 67bee6eb6e Fixed bug #30133 2004-09-27 22:21:52 +00:00
Marcus Boerger 7942ff14c4 Add new tests 2004-09-27 19:02:23 +00:00
Marcus Boerger 2728e52d58 MFH (discussed with Andi) 2004-09-27 19:01:50 +00:00
Ilia Alshanetsky 96184fe715 MFH: Fixed bug #30249 (Incorrect timeout check). 2004-09-27 17:30:47 +00:00
Marcus Boerger 5d5e004b34 MFH (1 fix, 1 warning) 2004-09-27 08:34:49 +00:00
Marcus Boerger 2e67579965 MFH 2004-09-26 21:52:51 +00:00
Ilia Alshanetsky f858b30f4e MFH:
Return FALSE when file cannot be found.
Specify full paths to the files used for the test.
2004-09-26 19:24:20 +00:00
Marcus Boerger 094aa8699d MFH add new tests 2004-09-26 18:29:46 +00:00
SVN Migration 3d2c4f5670 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-09-26 18:28:08 +00:00
Marcus Boerger ef3ea48ce0 MFH add new tests 2004-09-26 18:20:01 +00:00
SVN Migration a810fefdde This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-09-26 18:16:34 +00:00
Wez Furlong 2be9172661 MFH: Fix bug #30147 OO sqlite_fetch_object did not reset error handler 2004-09-26 01:41:40 +00:00
Wez Furlong 5c085a9224 BFN 2004-09-26 01:14:59 +00:00
Wez Furlong 1665957a8f MFH: configure check for getaddrinfo (Bug #30057) 2004-09-26 01:13:43 +00:00
Marcus Boerger 257f58c862 MFH lib substituation 2004-09-25 15:30:17 +00:00
Marcus Boerger c6744a5370 MFH unserialize fixes 2004-09-24 22:05:36 +00:00
Marcus Boerger 643c61277f - MFH unserialize fixes
# .re first
2004-09-24 22:05:14 +00:00
Marcus Boerger b790562222 BFN (MFHed) 2004-09-24 22:01:25 +00:00
Andi Gutmans 39f83fc506 - PHP 5.0.3-dev 2004-09-23 21:56:15 +00:00
Andi Gutmans 412fb096fa - Roll 5.0.2 2004-09-23 21:21:59 +00:00
Marcus Boerger c4c952f023 BFN 2004-09-23 18:45:27 +00:00
Marcus Boerger 10b2bb1cab MFH 2004-09-23 18:42:49 +00:00
Marcus Boerger 406847a6cd MFH Bugfix # 30209 2004-09-23 18:41:15 +00:00
SVN Migration 57c5bff123 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-09-23 18:38:35 +00:00
Dmitry Stogov 9062b2f967 Fixed bug #29566 (foreach/string handling strangeness (crash)). 2004-09-22 07:12:15 +00:00
Dmitry Stogov 29348ff48b Fixed bug #30182 (SOAP module processing WSDL file dumps core). 2004-09-22 05:57:36 +00:00
Uwe Schindler 2067727a80 changed order of processing of ini entries 2004-09-20 13:29:44 +00:00
Ilia Alshanetsky 6fcc1515cb MFH: Fixed bug #29913 (parse_url() is now binary safe). 2004-09-20 05:14:35 +00:00
Stanislav Malyshev 08e7f480e1 MFH destructor failure fix 2004-09-17 10:19:47 +00:00
Ilia Alshanetsky f521b61ce2 MFH: Fixed bug #30050 (Possible crash inside php_shutdown_config()). 2004-09-17 02:48:47 +00:00
Andi Gutmans 16bc64121f - Go with PHP 5.0.2RC1 2004-09-16 21:44:47 +00:00
Dmitry Stogov d8cd133a33 Fixed crash with SoapFault and register_shutdown_function(). 2004-09-16 08:11:07 +00:00
Sebastian Bergmann f1ec84159d MFH: ZTS fix. 2004-09-16 05:44:39 +00:00
Andi Gutmans b9a6022f15 - NEWS 2004-09-16 00:46:46 +00:00
Andi Gutmans b832343962 - MFH 2004-09-16 00:44:12 +00:00
Uwe Schindler 8e3e81256f Fixed bug #29805 (HTTP Authentication Issues) 2004-09-15 21:27:10 +00:00
Dmitry Stogov 24ec8acb2d Fixed invalid test name 2004-09-15 14:35:59 +00:00
Ilia Alshanetsky 820516e756 Fixed a bug causing ".123" * "90" and alike to return a 0. 2004-09-15 13:41:38 +00:00
Derick Rethans 09d555e3d0 - MFH: Windows has strcoll too. 2004-09-15 12:29:24 +00:00
Derick Rethans 9782bbd297 - MFH: Added new boolean (fourth) parameter to array_slice() that turns on the
preservation of keys in the returned array.
2004-09-15 11:51:56 +00:00
Dmitry Stogov 833331a53d Fixed possible crash 2004-09-15 10:35:09 +00:00
Dmitry Stogov a9b87039e4 Fixed bug #30045 (Cannot pass big integers (> 2147483647) in SOAP requests) 2004-09-14 12:13:39 +00:00
Magnus M��tt� 327125e313 Add missing stream unregister for sslv2 and 3. 2004-09-13 18:31:54 +00:00
Stefan Esser ce886edc0b MFH 2004-09-13 16:00:37 +00:00
Dmitry Stogov bb3e125185 Change soap's ctors to __construct(),
rename SoapClient->__call() to SoapClinet->__soapCall().
2004-09-13 11:54:06 +00:00
Stefan Esser f5722d61b4 MFH 2004-09-12 10:46:27 +00:00
Derick Rethans 7d77171b9b - Added the sorting flag SORT_LOCALE_STRING to the sort() functions which makes
them sort based on the current locale. (Derick)
2004-09-11 14:20:55 +00:00
Andi Gutmans 76d520e9a7 - MFH 2004-09-11 00:23:33 +00:00
Wez Furlong aa5feff190 BFN 2004-09-10 12:06:27 +00:00
Wez Furlong 16dd07c5e0 MFH: fix for Bug #29296 2004-09-10 11:44:10 +00:00
Dmitry Stogov 14c1dc4ab4 SoapClient->__call() is renamed to SoapClient->__soap_call(). 2004-09-10 09:03:25 +00:00
Dmitry Stogov 18079dd248 Using php_libxml_xmlCheckUTF8() from ext/libxml. 2004-09-10 09:00:32 +00:00
Wez Furlong ae5598fa85 MFH: avoid potential AT&T libc problems with tempnam() 2004-09-09 19:41:40 +00:00
Marcus Boerger 6183a1ed3e MFH Fix test script 2004-09-09 17:09:25 +00:00
Rasmus Lerdorf 177647c99b Stop at the index on an unmatched [ 2004-09-09 16:21:49 +00:00
Marcus Boerger 278aee14a5 MFH Drop namespace relict 2004-09-09 13:29:37 +00:00
Marcus Boerger 29048d8d7e Fix test 2004-09-09 11:33:31 +00:00
Marcus Boerger e3b65c75be MFH Fix __call's method signature 2004-09-09 09:54:06 +00:00
Marcus Boerger a3858e17e9 MFH signature check/method registration
# the new function is no ZEND_API in 5.0.* to prevent bumping API
2004-09-09 09:53:20 +00:00
Marcus Boerger 0d27154a49 MFH add new test 2004-09-09 07:46:43 +00:00
SVN Migration 9ab9402ed9 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-09-09 07:46:20 +00:00
Andi Gutmans db638b91b3 - MFH 2004-09-09 02:44:17 +00:00
Sara Golemon c1c1b21686 MFH (r.163) Handle maxlen when stream can't be mmaped 2004-09-08 18:45:05 +00:00
Rob Richards e62db3b3c8 MHF: fix issue with multiple xsl objects using registerPHPfunctions
- also fixes threading issue
2004-09-08 16:54:53 +00:00
Rob Richards f01310928c MFH: implement php_libxml_xmlCheckUTF8
- workaround for <= libxml2-2.6.13 function
2004-09-08 10:16:57 +00:00
Dmitry Stogov b003591f19 Make ext/soap work around libxml2 bug in xmlCheckUTF8 (2.6.7-2.6.13) 2004-09-07 14:41:29 +00:00
Marcus Boerger 9ae0e91ef4 MFH Fix handling of exceptions in dtors 2004-09-06 19:16:35 +00:00
Rob Richards c2c1590d52 BFN 2004-09-06 10:19:36 +00:00
Rob Richards 39916670cc MFH: Fixed bug #29945 (simplexml_load_file URL limitation 255 char) 2004-09-06 10:18:29 +00:00
Marcus Boerger 14b2c4a1f4 BFN 2004-09-05 17:43:37 +00:00
Marcus Boerger 2074b6ceee MFH bugfix 299885 2004-09-05 17:40:54 +00:00
Andi Gutmans 120ea84394 - MFH 2004-09-04 17:04:23 +00:00
Georg Richter 4ca31d911f MFH: LOAD DATA INFILE now uses PHP's fopen wrapper 2004-09-04 14:19:20 +00:00
Marcus Boerger 03a1a3675a MFH 2004-09-03 18:54:41 +00:00
Marcus Boerger 7052ece4e8 MFH: Fix protoe's 2004-09-03 18:41:10 +00:00
Ilia Alshanetsky f34dafccdb MFH: Adjusted input check. 2004-09-03 03:35:27 +00:00
Stanislav Malyshev 65052194b4 MFH: filestat fix 2004-09-02 09:44:59 +00:00
Derick Rethans 88d0d5427e - MFH: Added test for bug #29944. 2004-09-02 06:35:04 +00:00
Georg Richter 2c99f0230c fixed compiler warnings
fixed bug #29283
2004-09-02 04:52:07 +00:00
Ilia Alshanetsky ea138b85ab MFH: Fixed bug #29925 (Added a check to prevent illegal characters in
session key).
2004-09-02 02:44:12 +00:00
Marcus Boerger df93e470cc MFH: Fix seeking 2004-08-31 20:56:08 +00:00
SVN Migration e54698481c This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-31 20:54:32 +00:00
Sara Golemon 43004bcaaa MFH: Use user_agent ini setting if it's available. 2004-08-31 20:11:32 +00:00
Joe Orton 98c0dd4147 MFH: Do not rely on handling of integers which might be outside the
range of a 32-bit signed long.
2004-08-31 12:11:06 +00:00
Joe Orton 85f8b2a830 MFH: fix gettimeofday() tests to not fail if the same time is
returned by successive calls.
2004-08-31 11:49:19 +00:00
Antony Dovgal b8c51d4614 MFH: fix bug #29723 (file_get_contents() fails with the file:// wrapper under Win32) 2004-08-31 11:38:59 +00:00
Antony Dovgal 805fe58a28 MFH: this file shouldn't be in the repository at all 2004-08-31 08:31:45 +00:00
Ilia Alshanetsky f5c36b8d9e MFH: Added missing input validation to dio_write(). 2004-08-30 22:21:13 +00:00
Marcus Boerger 25ab185761 MFH: Add some information about array overloading 2004-08-30 18:49:49 +00:00
Rob Richards e7fcde565b MFH: remove cloning under ze1_compatibility_mode
- minor BC break but doesnt work right under compat mode anyways
2004-08-30 17:29:58 +00:00
Rob Richards 6164ea4840 MFH: remove cloning under ze1_compatibility_mode
- minor BC break but doesnt work right under compat mode anyways
2004-08-30 15:09:07 +00:00
Rob Richards 470ca9ef6f MFH: remove clone functionality 2004-08-30 15:00:07 +00:00
Stanislav Malyshev beffd8738e MFH fix #29893 2004-08-30 09:13:40 +00:00
Antony Dovgal bce14e2c6f MFH: add testcase for bug #29893 2004-08-30 09:11:06 +00:00
SVN Migration af2ee723dc This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-30 09:07:19 +00:00
Marcus Boerger 975771b431 MFH: String offset starts with 0 2004-08-29 19:15:57 +00:00
Ilia Alshanetsky 3f5e121f2b MFH: Fixed leak when serializing protected & private properties. 2004-08-29 17:16:21 +00:00
Marcus Boerger a000fe6c06 MFH: Bugfix #29882 isset crashes on arrays 2004-08-29 13:29:47 +00:00
Sergey Kartashoff ff8c3d2d67 - A fix for building of shared mnogosearch module 2004-08-29 10:59:15 +00:00
Derick Rethans e6df40e831 - MFH: Fixed bug #29873 (No defines around pcntl_*priority definitions). 2004-08-28 12:20:41 +00:00
Christian Stocker b559075a02 Marking DOM and XSL as "Working". This should have happened with the
release of PHP 5.0.0 already.
2004-08-27 22:41:38 +00:00
Marcus Boerger 1d87b34375 MFH: Fix by (mathieu dot bruneau at argontechnologies dot ca) 2004-08-27 20:39:17 +00:00
Andi Gutmans 942a83b246 - MFH 2004-08-27 16:49:54 +00:00
Dmitry Stogov 92689ec8e0 Fixed bug #29842 (soapclient return null value) 2004-08-27 07:06:07 +00:00
Ilia Alshanetsky dfb664c946 MFH: Fixed a nasty resource/memory/disk-space leak when opening zlib files
via wrapper stacking ala compress.zlib://http://...
2004-08-26 23:36:08 +00:00
Marcus Boerger 8c4eede77d MFH: Enforce semantics: Classes cannot extend Interfaces 2004-08-26 23:02:55 +00:00
Marcus Boerger 4ad82c5ef2 MFH: Add test 2004-08-26 23:01:45 +00:00
Marcus Boerger ca612d3fc0 MFH: Fix test 2004-08-26 23:01:21 +00:00
SVN Migration 87fca31a3f This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-26 22:53:52 +00:00
Marcus Boerger 54b2a4d6a0 BFN 2004-08-26 22:44:20 +00:00
Marcus Boerger 82a5d700e3 MFH: Bugfix 29828 2004-08-26 22:43:32 +00:00
Marcus Boerger 982ac8b7a2 MFH 2004-08-26 22:30:16 +00:00
SVN Migration 6aed779dc8 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-26 22:24:49 +00:00
Rob Richards 69fe08beb2 not experimental 2004-08-26 20:13:57 +00:00
Dmitry Stogov 412bae8482 Memory leaks were fixed. 2004-08-26 18:55:54 +00:00
Dmitry Stogov 27868d1799 Fixed bug #29839 (incorrect convert (xml:lang to lang)) 2004-08-26 18:36:47 +00:00
Dmitry Stogov bb19590b7e Fixed bug #29795 (SegFault with Soap and Amazon's Web Services)
Fixed bug #27994 (segfault with Soapserver when WSDL-Cache is enabled)
2004-08-26 15:23:57 +00:00
Dmitry Stogov 48dba110e2 Fixed bug #29844 (SOAP doesn't return the result of a valid SOAP request).
Fixed bug #29830 (SoapServer::setClass() should not export non-public methods).
2004-08-26 12:20:13 +00:00
Ilia Alshanetsky 255f9fc072 MFH: Fixed bug #29808 (array_count_values() breaks with numeric strings). 2004-08-26 00:26:22 +00:00
Andrei Zmievski 8f9fa59341 MFB. 2004-08-25 20:48:25 +00:00
Marcus Boerger 872f6e7af8 MFH: No short tags 2004-08-25 07:26:36 +00:00
Andrey Hristov ecca999733 . 2004-08-25 07:20:30 +00:00
Andi Gutmans 38d64188ff - Improve wording 2004-08-25 01:06:29 +00:00
Andi Gutmans 048aa76cc9 - NEWS 2004-08-25 01:04:27 +00:00
Andi Gutmans 5c3249d954 - MFH 2004-08-25 01:02:38 +00:00
Andrey Hristov b15b80c1b7 MFH 2004-08-24 22:03:12 +00:00
Marcus Boerger 5facf4becc TSRM fix 2004-08-24 21:41:02 +00:00
Marcus Boerger f5ebf71f49 Add new test 2004-08-24 21:40:12 +00:00
SVN Migration 7a69f34c69 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-24 21:35:47 +00:00
Andrei Zmievski f1b7a88393 MFB 2004-08-24 21:02:52 +00:00
Ilia Alshanetsky 853d714008 MFH: Fixed bug #29821 (Fixed possible crashes in convert_uudecode() on
invalid data).
2004-08-24 15:25:59 +00:00
Rob Richards 077b8f2d25 MFH: fix segfault when object cloned 2004-08-24 13:33:48 +00:00
Christian Stocker b6bb43ef94 MFH ;)
(This extension is no more experimental)
2004-08-24 11:50:53 +00:00
Ilia Alshanetsky 6f20f9d285 MFH: Fixed possible crash inside dio_read(). 2004-08-23 17:27:46 +00:00
Zeev Suraski 2fb5c4394b Fix names 2004-08-23 13:14:27 +00:00
Derick Rethans 9ca8a571e9 - There was a bug # attached to this fix. 2004-08-23 09:56:05 +00:00
Derick Rethans 8ee05c9da8 - Fixed Apache 2.0 SAPI build against Apache 2 HEAD. (Patch by Joe Orton) 2004-08-23 09:00:09 +00:00
Ilia Alshanetsky a4430a9cfe MFH: Using int when long should be used. 2004-08-22 18:05:27 +00:00
Andrey Hristov 2be03f0d73 MFH (bug 26737) 2004-08-21 14:11:56 +00:00
Sara Golemon 85fe5f8c34 MFH Bufix#29777 Bad commenting 2004-08-21 00:01:44 +00:00
Ilia Alshanetsky c7f52698c1 MFB: removed unneeded bits. 2004-08-20 13:52:47 +00:00
Derick Rethans d775bca68f - 78 chars please. 2004-08-20 06:13:41 +00:00
Ilia Alshanetsky 6c763f3721 MFH: Added more missing cURL options. 2004-08-20 00:56:05 +00:00
Brian France 949e461e8f [MFH] If you send a post with a content-type header and then the next post without the content-type header, raw_post_data will not be set. This is because SG(request_info).post_entry is set to the first requests function pointer which makes it follow the wrong code path. 2004-08-19 20:34:04 +00:00
Antony Dovgal 59ed068c78 BFN 2004-08-19 15:23:54 +00:00
Antony Dovgal d8cd7dac07 MFH: ip2long() issues 2004-08-19 15:15:32 +00:00
Antony Dovgal 4945317c28 MFH: fix #29737 (ip2long should return -1 if IP is 255.255.255.255 and FALSE on error) 2004-08-19 14:03:44 +00:00
Derick Rethans 34f4400502 - Reorder 2004-08-19 12:44:35 +00:00
Christian Stocker 259f662488 MFH
- Fixed bug #29657 (xml_* functions throw non descriptive error).
  (Christian, Rob)
- Fixed bug #29711 (Changed ext/xml to default to UTF-8 output). (Rob)
2004-08-19 12:29:43 +00:00
Ilia Alshanetsky d349734059 MFH: Fixed bug #29727 (Added missing CURL authentication directives). 2004-08-18 21:27:27 +00:00
Antony Dovgal fa5f20cfce MFB: typo in config.m4 (potential configuration problem with Stronghold) 2004-08-18 07:19:45 +00:00
Andi Gutmans 435fff2cb1 - Fix typos 2004-08-17 23:09:37 +00:00
Antony Dovgal 9173e270b0 MFH: fix typo 2004-08-17 10:58:07 +00:00
Ilia Alshanetsky 40645cc0a6 MFH: Fixed bug #29594 (Use PHP's own tmpfile() implementation). 2004-08-16 23:08:56 +00:00
Zeev Suraski 33e114b37e *** empty log message *** 2004-08-16 12:34:20 +00:00
Zeev Suraski be85bd83e8 MFH 2004-08-16 12:25:40 +00:00
Marcus Boerger 29099a7470 BFN 2004-08-16 08:51:12 +00:00
Marcus Boerger 8823289f9f MFH: Fix bug #29447: Reflection API issues 2004-08-16 08:49:48 +00:00
Ilia Alshanetsky 78363147b8 MFH: Fixed bug #29678 (opendir() with ftp:// wrapper segfaults if path
does not have trailing slash).
2004-08-16 01:41:17 +00:00
Marcus Boerger ac7665fdc2 MFH: Remove unnecessary check 2004-08-15 15:50:37 +00:00
Georg Richter 1410d8c0b2 fixed default for mysqli_fetch_array 2004-08-15 05:50:29 +00:00
Marcus Boerger 5a4158421c MFH: Add missing check 2004-08-14 19:04:01 +00:00
Georg Richter 945115968c fixed bug #29656 (segfault on result and statement properties) 2004-08-13 16:27:35 +00:00
Antony Dovgal 970f1f9c7f MFH: fix yet another annoying compile warning 2004-08-13 15:02:05 +00:00
Antony Dovgal 65ef16ef31 MFH: fix compile warning 2004-08-13 14:54:50 +00:00
Derick Rethans 0186acacdb - MFH: Added PHP_EOL constant that contains the OS way of representing
newlines. (Patch by Paul Hudson)
2004-08-13 07:08:46 +00:00
Georg Richter bc4a269d3c minor fix in mysqli_prepare: copying stmt errormessag to mysql structure 2004-08-12 22:11:46 +00:00
Andi Gutmans 291441a34c - Back to 5.0.2-dev 2004-08-12 20:53:19 +00:00
Andi Gutmans d8c1e99f02 - Roll 5.0.1 2004-08-12 20:39:36 +00:00
Chuck Hagenbuch 8d0cc271bf More spaces -> tabs. 2004-08-12 19:32:18 +00:00
Ilia Alshanetsky bbde60d6d2 MFH: Properly fix the msgno check inside imap_fetchbody(). 2004-08-12 19:20:17 +00:00
Chuck Hagenbuch e2b820f0ea MFH: fix. 2004-08-12 18:02:03 +00:00
Derick Rethans c970dbb647 - Reorder a bit and add . 2004-08-12 07:25:32 +00:00
Andi Gutmans 29c32f04e3 - Back to -dev 2004-08-12 06:39:26 +00:00
Andi Gutmans 00c6777aa1 - 5.0.1RC2 2004-08-12 06:35:22 +00:00
Magnus M��tt� 143ae77156 Add missing NEWS entry (bug 29147). 2004-08-12 05:42:13 +00:00
Marcus Boerger 87ba25b722 MFH: Change to use md5_file() 2004-08-12 00:38:12 +00:00
Ilia Alshanetsky dc77b5700c MFH: Fixed memory leak. 2004-08-11 23:25:52 +00:00
Ilia Alshanetsky 0e5c01290d Fixed bug #29607 (highlighting code with HEREDOC produces invalid output). 2004-08-11 22:38:31 +00:00
Derick Rethans ba16543ef5 - Tix Fypo 2004-08-11 15:23:00 +00:00
Derick Rethans f65e4feda4 - MFH: Added a notice to getimagesize in case zlib is not available and a
compressed SWF movie has been passed to the function.
2004-08-11 12:31:37 +00:00
Derick Rethans 20181fde3d - Reworded this a bit 2004-08-11 12:24:41 +00:00
Christian Stocker 491ed1813e MFH (fix test) 2004-08-11 08:24:41 +00:00
Derick Rethans caa5dbe679 - MFH: Patch to allow the Zend memory allocators to be disabled. 2004-08-11 06:13:12 +00:00
Sara Golemon 7e6d72f030 MFH: Fix format specifiers 2004-08-11 04:29:26 +00:00
Sara Golemon 6ea962c767 MFH: $errmsg should have been forced reference 2004-08-11 04:10:44 +00:00
Marcus Boerger c87b2d0cee BFN (small but important change) 2004-08-10 22:40:14 +00:00
Ilia Alshanetsky c2c31547c2 Bug fixing news. 2004-08-10 22:17:31 +00:00
Ilia Alshanetsky 21851b0001 MFH: Fixed bug #29606 (php_strip_whitespace() prints to stdout rather then
returning the value).
2004-08-10 22:16:50 +00:00
Dmitry Stogov bd96cca64f Fixed bug #28969 (Wrong data encoding of special characters) 2004-08-10 16:30:31 +00:00
SVN Migration 02893ad216 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-10 16:18:09 +00:00
Wez Furlong 4f88703159 BFN 2004-08-10 13:47:30 +00:00
Wez Furlong abc62474bf MFH: Fix for #29256 2004-08-10 13:45:58 +00:00
Christian Stocker 3a9754715a MFH (Fix segfault on error in xslt) 2004-08-10 08:02:00 +00:00
Andi Gutmans 2f212ab8d5 - Back to -dev 2004-08-10 07:28:09 +00:00
Andi Gutmans 71be1ed5f1 - 5.0.1RC1 2004-08-10 07:17:05 +00:00
Moriyoshi Koizumi 1c6896076f - Bugfix #29493 (extract(array, EXTR_REFS) misbehaves with elements referred
twice or more times)
2004-08-10 06:01:20 +00:00
Andi Gutmans 6a2d265af6 - The documentation team has re-wroten the installation part of the manual. 2004-08-10 05:36:12 +00:00
Ilia Alshanetsky 6fe9c3735a MFH: Fixed bug #29581 (Typo inside php.ini comments for mysql.trace_mode). 2004-08-10 00:44:23 +00:00
Andi Gutmans 5d43cf4ec4 - Update NEWS 2004-08-09 22:24:10 +00:00
Andi Gutmans 8b3b1eb121 Update credits for php docs 2004-08-09 21:53:19 +00:00
Dmitry Stogov 836a7b1a88 Included ext/soap fixes from CVS HEAD. 2004-08-09 05:50:06 +00:00
Georg Richter c26edafb17 fixed bug #29577 (MYSQLI_CLIENT_FOUND_ROWS undefined) 2004-08-09 04:33:40 +00:00
Ilia Alshanetsky a9bf810ba2 Remove \r characters from file. 2004-08-08 21:25:55 +00:00
Christian Stocker a737e92b08 Fixed bug #29573. 2004-08-08 18:09:46 +00:00
Christian Stocker 54ae55a949 MFH (fix for Bug #29573 : Segmentation fault when php function(called from XSLT templat) throw exception
and Zero Byte Memory Leaks)
2004-08-08 18:05:47 +00:00
Wez Furlong 5ab53094fa BFN 2004-08-07 21:04:51 +00:00
Wez Furlong aff24aed0d MFH: Fix for Bug #29490 from Michael Sisolak 2004-08-07 21:01:43 +00:00
Sara Golemon b915644ec4 MFH ZTS Fix 2004-08-06 17:35:59 +00:00
Wez Furlong 28c71a667a MFH: avoid possible segfault with stream_socket_client and bogus flags. 2004-08-06 14:18:49 +00:00
Ilia Alshanetsky d45c4f86d3 MFH: php_error() -> php_error_docref() 2004-08-05 23:57:53 +00:00
Edin Kadribasic 8060534f63 MFH: Export php_libxml_error_handler for windows build (#29541) 2004-08-05 21:03:15 +00:00
Antony Dovgal 80bdf7eae5 MFH: remove all references to @ thing, as it's not recommended 2004-08-05 14:19:59 +00:00
Ilia Alshanetsky 2dad2b3882 MFH: Eliminate unneeded variable. 2004-08-05 00:44:32 +00:00
Frank M. Kromann aa0a80bea8 Revert. ADD_EXTENSION_DEP is available in this branch! 2004-08-04 19:22:12 +00:00
Frank M. Kromann dec171c4bf No extension dependency in this branch 2004-08-04 17:22:14 +00:00
Frank M. Kromann 6d5779844f MFH: Move iconv exports to the iconv extension and make libxml depend on iconv 2004-08-04 17:13:11 +00:00
SVN Migration 94ed0368b9 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-04 16:46:49 +00:00
Zeev Suraski 6c8d9c8c8e Fix prototypes 2004-08-04 16:39:56 +00:00
Zeev Suraski 9de0be49d6 Fix prototypes 2004-08-04 14:40:53 +00:00
Georg Richter 5a76218edd fixed bug #29522 2004-08-04 13:02:40 +00:00
Marcus Boerger d84c321376 MFH missing part 2004-08-04 10:32:43 +00:00
Ilia Alshanetsky b3262ff512 MFH: Fixed argument handling in sun* functions. 2004-08-04 00:28:05 +00:00
Edin Kadribasic a825563c0b Typofix 2004-08-03 22:56:15 +00:00
Edin Kadribasic da476e0da9 MFH 2004-08-03 22:50:18 +00:00
Marcus Boerger 46107c39a4 MFH 2004-08-03 17:10:58 +00:00
Marcus Boerger a263d88c81 BFN 2004-08-03 17:07:56 +00:00
Marcus Boerger 9158cd2494 - MFH Bug #29505 get_class_vars() severely broken when used with arrays 2004-08-03 17:02:35 +00:00
SVN Migration 2e98f2dd1a This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-03 16:59:54 +00:00
Antony Dovgal 902b4bda6a MFH: typo in ini parameter name 2004-08-03 06:26:59 +00:00
Antony Dovgal 87b52bb5cd MFH: fix typo in php.ini-dist & php.ini-recommended 2004-08-03 06:21:17 +00:00
Greg Beaver e6199b5279 commit for win32 - binary so line endings are always preserved - ..and in PHP_5_0, where it also belongs 2004-08-03 04:36:56 +00:00
SVN Migration e7f995106c This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-08-03 04:36:01 +00:00
Ilia Alshanetsky 3bcb1f3af1 MFH: Allow sqlite_fetch_column_types() to properly handle table names with
spaces in them.
2004-08-02 22:43:42 +00:00
Marcus Boerger 13a652c81c MFH Change to use memcmp instead of strcmp 2004-08-02 22:43:16 +00:00
Ilia Alshanetsky 5ddd062e36 MFH: A gentler (performance wise) allocation of buffer for temp variables. 2004-08-02 02:35:03 +00:00
Marcus Boerger 4bedc6bb31 - Add new tests 2004-08-01 21:55:58 +00:00
Marcus Boerger 70f94e52ea - Enforce protocol on magic methods/functions 2004-08-01 21:55:39 +00:00
Wez Furlong 87c3363fa9 MFH usleep fix, and BFN. 2004-08-01 00:35:11 +00:00
Wez Furlong ca1dc06e04 MFH: zts fix 2004-07-31 16:37:18 +00:00
Wez Furlong b5ed0a1d3d MFH: streams fixes 2004-07-31 11:00:11 +00:00
Wez Furlong 19c8eeb4e8 MFH: zts fix for ini entries and dl() 2004-07-30 15:05:02 +00:00
Wez Furlong 293e62c99d MFH: win32 zts fix 2004-07-30 14:39:18 +00:00
Wez Furlong 2da7dd5982 MFH: various ZTS fixes 2004-07-30 14:24:59 +00:00
Edin Kadribasic 6325b1b630 MFH 2004-07-30 12:40:54 +00:00
Edin Kadribasic 9244e0eee1 MFH 2004-07-30 09:59:06 +00:00
Edin Kadribasic 712d951ffc MFH 2004-07-30 09:30:30 +00:00
Ilia Alshanetsky 40773632e0 MFH: Fixed bug #29443 (Sanity check for wbmp detection). 2004-07-30 01:10:42 +00:00
Edin Kadribasic 88628a2319 MFH 2004-07-29 22:26:52 +00:00
Edin Kadribasic 31120ba5f7 MFH: Fix informix compilation on Windows (bug #29340) 2004-07-29 21:12:47 +00:00
Timm Friebe 75276870db - MFH:
. Fixed bug #29064 (Exact numeric/decimal/money datatypes lose precision)
  . Fixed bug #27843 (sybase_query() triggers (spurious?) notices when
    query is a stored procedure)
  . Fixed multiple memory leaks with sybase_unbuffered_query()
  . Changed sybase_query() to ignore store_results = false in  buffering
    mode, it would yield unpredictable results
  . Fixed sybase_unbuffered_query() when used with store_results = false
  . Changed sybase_fetch_object() to ignore second argument when passed
    as NULL
  . Made sybase_data_seek() error message more verbose
  . Fixed memory leak in shutdown when not all rows where selected in an
    unbuffered query
# sort of, empty_string -> STR_EMPTY_ALLOC patch ommitted
2004-07-29 20:05:46 +00:00
SVN Migration fc0b122460 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-29 03:58:02 +00:00
Ilia Alshanetsky d976c362ac MFH: Fixed but #29437 (Possible crash inside array_walk_recursive()). 2004-07-29 00:35:12 +00:00
Wez Furlong 6c82c26884 BFN 2004-07-29 00:17:01 +00:00
Wez Furlong a0ef3e1865 MFH: #29431 2004-07-28 23:53:04 +00:00
Wez Furlong 4f91645642 MFH:
#29258: variant_date_from_timestamp() does not honour timezone
#29392: com_dotnet crashes when echo'ing an object
2004-07-28 23:48:26 +00:00
Wez Furlong 46b2bef868 Moved to PECL 2004-07-28 23:39:36 +00:00
Ilia Alshanetsky 26319ee1a1 MFH: Better address availability check. 2004-07-28 23:34:30 +00:00
Ilia Alshanetsky 42a8242676 MFH: Fixed possible crash in stream_socket_recvfrom() when length
parameter has a negative value.
2004-07-28 23:21:56 +00:00
Marcus Boerger 57ab773c70 MFH 2004-07-28 22:55:26 +00:00
Andi Gutmans 219364ee55 - Fix MAC OSX to always use native DSO loading 2004-07-28 19:07:26 +00:00
Christian Stocker 8b5fc29c7a MFH
Fixed bug #29409 (Segfault in PHP functions called from XSLT). (Rob)
2004-07-28 12:42:16 +00:00
Ilia Alshanetsky 21f4b69b2b MFH: Fixed bug #29342 (strtotime() does not handle empty date string
properly).
2004-07-28 01:44:41 +00:00
Ilia Alshanetsky f76ce400eb MFH: Fixed bug 29395 (sqlite_escape_string() returns bogus data on empty
strings).
2004-07-27 16:40:46 +00:00
Ilia Alshanetsky 16204148bb MFH: Added missing comma. 2004-07-27 12:44:35 +00:00
Ilia Alshanetsky 1f2d017ae1 MFH: Fixed bug #29349 (imagecreatefromstring() crashes with external GD
library).
2004-07-27 00:27:07 +00:00
Georg Richter 1b10ad424a MFH: fixed bug 29335 2004-07-26 07:22:01 +00:00
Georg Richter 3e65f6bf57 MFH: fixed bug in mysqli->client_version 2004-07-26 05:45:41 +00:00
Marcus Boerger f84d03b2bc - Update/Add tests 2004-07-25 19:35:30 +00:00
SVN Migration 2db28891e4 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-25 19:21:22 +00:00
Ilia Alshanetsky 7adc26fd8b MFH: Fixed bug #29369 (Uploaded files with ' or " in their names get their
names truncated at those characters).
2004-07-25 19:19:28 +00:00
Marcus Boerger fe80df5446 BFN 2004-07-25 17:38:44 +00:00
Marcus Boerger 8588815ef3 - MFH: Fix bug #29368 : The destructor is called when an exception is
thrown from the constructor
2004-07-25 17:37:55 +00:00
Georg Richter a70fc67b0b fixed bug #29311 2004-07-23 12:48:20 +00:00
SVN Migration b5c53ae6c7 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-23 12:47:37 +00:00
Edin Kadribasic 3d018fb061 MFB: Updated version number 2004-07-23 02:28:36 +00:00
Ilia Alshanetsky 3845e2c145 MFH: Fixed bug #29333 (output_buffering + trans_sess_id can corrupt output) 2004-07-23 02:05:51 +00:00
Stefan Esser 1930c2c33b MFH 2004-07-22 22:59:11 +00:00
SVN Migration 1e2b92b517 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-22 22:39:01 +00:00
Marcus Boerger 983fa5a21e Fix testcase 2004-07-22 18:39:45 +00:00
Georg Richter 3ecbb5c314 MFH: changed warning (bug #29298) for outdated client library 2004-07-22 07:25:31 +00:00
Sara Golemon 8fa1628958 MFH: This should fix binary safety for bound results. 2004-07-22 03:26:59 +00:00
Edin Kadribasic e52b580cad MFH: Fix for #28929 by Michael Sisolak 2004-07-21 22:53:27 +00:00
Edin Kadribasic 4b28e0a8f1 MFH: Build fix 2004-07-21 22:22:21 +00:00
Ilia Alshanetsky 91f5ceb3be MFH: Fixed bug #29209 (imap_fetchbody() doesn't check message index). 2004-07-21 21:57:09 +00:00
Marcus Boerger 603758b484 BFN 2004-07-21 18:38:23 +00:00
Marcus Boerger b6b575c1d5 MFH: Fixded #29291: get_class_vars() return names with NULLs 2004-07-21 18:37:36 +00:00
Christian Stocker e2f3142c78 MFH. Fix for Bug 29010 "make test does not wait to email address" (by Sebastian Nohn) 2004-07-21 11:20:33 +00:00
Ilia Alshanetsky 7623887079 MFH: Abort earlier on invalid format. 2004-07-21 00:14:50 +00:00
Moriyoshi Koizumi 1bd6ec4c91 - MFH (ctype.c: 1.31): Correct range checks.
- MFH (ctype.c: 1.31): Normalize negative values.
2004-07-20 20:09:27 +00:00
Moriyoshi Koizumi 33a6aefce8 oops... 2004-07-20 19:36:00 +00:00
Marcus Boerger d3f8aaecd8 BFN 2004-07-20 19:30:09 +00:00
Marcus Boerger 049cca1711 MFH 2004-07-20 19:25:18 +00:00
Moriyoshi Koizumi a40df45348 - MFH (iconv.c: 1.119): Fix possible leaks / segfaults in persistent iconv
filter.
2004-07-20 18:48:23 +00:00
Marcus Boerger 8f42eaae01 BFN 2004-07-20 18:25:48 +00:00
Marcus Boerger ebeefd9f7d MFH bugfix 28895 2004-07-20 18:23:49 +00:00
Moriyoshi Koizumi 646f9a4a8b - MFH (filters.c: 1.41): Add more null checks. 2004-07-20 18:17:07 +00:00
Moriyoshi Koizumi b4fa1661af - MFH (filters.c: 1.40): pemalloc() might return NULL 2004-07-20 18:04:36 +00:00
Stanislav Malyshev ba3c63dbc9 export ini parser 2004-07-20 08:45:04 +00:00
Sebastian Bergmann 350535d498 BFN: Fixed ReflectionClass::getMethod() and ReflectionClass::getProperty() to raise an ReflectionException instead of returning NULL on failure. 2004-07-20 05:48:45 +00:00
Ilia Alshanetsky 467caa4307 MFH: Fixed bug #29226 (ctype_* functions missing validation of numeric
string representations).
2004-07-20 01:03:18 +00:00
Sergey Kartashoff 01b6956d61 - A Bug #29147 was fixed. Thanks to Antony Dovgal <tony2001 at phpclub.net>
for his patch.
2004-07-19 19:46:52 +00:00
Marcus Boerger 61c3a669b4 - MFH protos and error message 2004-07-19 19:24:37 +00:00
Moriyoshi Koizumi befb6e9b80 - MFH (bug29119.phpt: 1.2): Fix test name 2004-07-19 18:49:46 +00:00
Moriyoshi Koizumi 35e43dabe1 - MFH (html.c: 1.98, bug29199.phpt: 1.1): Fix bug #29199 (html_entity_decode()
misbehaves with UTF-8)
2004-07-19 17:53:00 +00:00
SVN Migration b905779950 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-19 17:51:42 +00:00
Moriyoshi Koizumi 04c32887f1 - MFH (iconv.c: 1.118): Fix a bug in iconv stream filter that prevents
pending buckets from being processed.
2004-07-19 08:35:48 +00:00
Moriyoshi Koizumi e0a39d68d8 - MFH (config.m4: 1.52): Fix VPATH build. (patch by Joe Orton) 2004-07-19 05:09:46 +00:00
Moriyoshi Koizumi 92ec8541c1 - MFH: rename php_compat.h to php_onig_compat.h to avoid name conflict.
(reported by Joe Orton, thanks.)
2004-07-19 05:06:01 +00:00
SVN Migration 82a7ef78f3 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-19 05:04:34 +00:00
Ilia Alshanetsky 236c42c14e MFH: Fixed bug #28633 (sprintf incorrectly adding padding to floats). 2004-07-18 17:28:04 +00:00
SVN Migration b8fdc56a8b This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-18 17:27:51 +00:00
Rob Richards 17ad61bd7f enable exslt support for win32 builds
WS fixes for exslt tests
2004-07-18 13:22:46 +00:00
Rob Richards ec1507ea9d add missing optional value param to createElementNS (chregu) 2004-07-18 13:15:50 +00:00
Rob Richards 69bd1f31fd Fixed bug #29221 (Segfault using DOM ownerDocument in a PHP object) 2004-07-18 11:44:25 +00:00
Moriyoshi Koizumi b9d4af72e9 - MFH (sapi_apache2.c: 1.41): request_dtor should be called if a fatal error
occurs during activation phase.
2004-07-17 21:31:43 +00:00
Sara Golemon fbbc036830 BFN 2004-07-16 23:45:21 +00:00
Sara Golemon c2b0fdd647 MFH: convert.* filters not consuming buckets_in on PSFS_FLUSH_* 2004-07-16 23:42:00 +00:00
Marcus Boerger 3706b626fe BFN 2004-07-16 07:27:34 +00:00
Marcus Boerger edbfc48fdd MFH 2004-07-16 07:26:49 +00:00
Ilia Alshanetsky 59c6886c65 Fixed bug #28800 (strings beginning with "inf" improperly converted). 2004-07-16 02:02:09 +00:00
SVN Migration 8091552925 This commit was manufactured by cvs2svn to create branch 'PHP_5_0'. 2004-07-15 19:41:23 +00:00
Marcus Boerger 1916223883 - Fix prototype 2004-07-15 19:41:22 +00:00
Marcus Boerger f2377c4d1f Synch comments 2004-07-15 19:09:37 +00:00
Dan Kalowsky f20849d12e Bug 29058 (patch submitted by bug reporter) 2004-07-15 15:09:12 +00:00
Magnus M��tt� cfc8accd3e Test for bug 26737:
Protected and private variables are not saved on serialization
when a user defined __sleep is used.
2004-07-15 11:52:04 +00:00
Antony Dovgal f6eb507b2c fix #29012 (Potential race during first connection) thanks to cjbj at hotmail dot com 2004-07-15 11:00:14 +00:00
Ilia Alshanetsky a75608c1de Fixed Bug #29075 (strnatcmp() incorrectly handles whitespace).
# Original Patch by: curt@php.net
2004-07-15 01:26:03 +00:00
5a9875f293 ChangeLog update 2004-07-15 00:33:10 +00:00
Edin Kadribasic 546e5bbc43 Made php -m output sorted case-insensitevly 2004-07-14 22:30:29 +00:00
Stefan Esser 90f151470c same bug. 2004-07-14 09:55:24 +00:00
Derick Rethans edce707f3b - Fixed text. 2004-07-14 09:54:02 +00:00
Stefan Esser 446f4d1bc2 Security Fix broken! Destroyed Basic auth. Blame: me
4.3.x not affected
2004-07-14 09:43:26 +00:00
Stanislav Malyshev d673ec0184 be consistent with write_dimension 2004-07-14 09:04:13 +00:00
Stanislav Malyshev 28d72ce2fd fix #28957 2004-07-14 09:01:58 +00:00
John Coggeshall 51ae1cc7bd Changing the Tidy version to 2.0 2004-07-14 02:41:53 +00:00
12c826c2e7 ChangeLog update 2004-07-14 00:33:30 +00:00
Sara Golemon c4bf45e39a Bugfix# 28829 bcmath values for 0, 1, and 2 initialized/freed at wrong time for threaded sapis. 2004-07-14 00:14:43 +00:00
Zeev Suraski 2ec89aa8e1 Add {{{ proto's 2004-07-13 20:41:55 +00:00
Andi Gutmans c18badbfbf - 5.0.1-dev 2004-07-13 19:56:49 +00:00
Marcus Boerger 1ea22c9004 Bugfix #29116 Zend constant warning uses memory after free (jdolecek at NetBSD dot org) 2004-07-13 19:22:11 +00:00
Andi Gutmans 399e2ca69f - Roll PHP 5.0.0 2004-07-13 19:05:31 +00:00
Wez Furlong cfb84391d0 add missing break 2004-07-13 17:14:49 +00:00
Georg Richter bfd3c9ecfb prototype fixes 2004-07-13 17:04:16 +00:00
Rob Richards d64a00da04 initial xmlwriter code 2004-07-13 17:01:30 +00:00
Wez Furlong 971fcd4254 Looks like Sara forgot to change this too. 2004-07-13 16:34:56 +00:00
Georg Richter f61dbf06a1 changed mysqli_stmt_reset (returns now bool instead of void) 2004-07-13 16:12:28 +00:00
Stefan Esser 0b9d614988 Fixed typo 2004-07-13 11:30:50 +00:00
Alan Knowles 6284b34e6e remove test dependance on postgres ** this still fails however 2004-07-13 07:20:45 +00:00
Alan Knowles ad2b89c9a3 ensure that test passes on systems without postgres built in. 2004-07-13 07:12:06 +00:00
196259d334 ChangeLog update 2004-07-13 00:32:43 +00:00
Wez Furlong ae40d0ef2a Fix file_get_contents() bug... 2004-07-12 20:59:24 +00:00
Timm Friebe e532feb29c - Initial release 2004-07-12 20:26:53 +00:00
Ilia Alshanetsky 905fbfd85e Added missing constant and correct bound column retrieval. When bound
columns are specified only return status (TRUE/FALSE) indicator.
2004-07-12 20:12:39 +00:00
Ilia Alshanetsky ddb32b11b2 Fixed a bug that could result in false failed query reporting on
INSERT/UPDATE/DELETE queries.
2004-07-12 20:09:19 +00:00
Ilia Alshanetsky 11371cd0a8 Missing patch. 2004-07-12 18:49:47 +00:00
Ilia Alshanetsky 7daa1cfecc Fixed bug #28999 (fixed behaviour of exec() to work as it did in 4.X). 2004-07-12 18:48:30 +00:00
Ilia Alshanetsky a8996a8ac6 Fixed bug #29086 & #28064 (PHP crashes on extremly long scripts). 2004-07-12 17:47:29 +00:00
Ilia Alshanetsky 0ad4c5037c Touch the file so that build system does not try to rebuild it. 2004-07-12 17:44:40 +00:00
Andi Gutmans 334ddd1248 - Convert zend_class_entry -> zend_class_entry * 2004-07-12 16:38:45 +00:00
Christian Stocker 14a61929b9 implement the clone code for the XSLTProcessor object and fix #29108
"xslt segfaults when ze1_compatibility_mode is on" (By Rob Richards)
2004-07-12 13:04:01 +00:00
Antony Dovgal 08486a0ea3 fix #28978 (multiple OCIBindByName on the same placeholder eats memory) 2004-07-12 07:40:05 +00:00
83e4bb727b ChangeLog update 2004-07-12 00:32:48 +00:00
Andrey Hristov c401890d17 reorder + add 2004-07-11 21:41:33 +00:00
Andrey Hristov 0eef82a733 fixing bug #28974 : overflow in array_slice()
The same kind of overflow appeared in array_splice(), substr() and
substr_replace()
2004-07-11 21:15:04 +00:00
Stefan Esser 0e8de752fd Ooups... 2004-07-11 21:14:50 +00:00
Stefan Esser 8c075de7c7 Fixed: PARSE_TYPE parameter to input_filter
Fixed: input_filter should also be able to filter empty variables by name
2004-07-11 20:13:39 +00:00
Andrey Hristov 268d3d7ba3 fixing bug #28739
array_*diff() and array_*intersect() not clearing the fci cache before work.
FCI call cache was introduced in HEAD. All functions that perform sorting
of arrays clear the fci cache before work. array_*diff() and\ array_*intersect()
were somehow missed to be updated.
2004-07-11 19:20:05 +00:00
Andrey Hristov bc69bdb01a fixing the name of the test 2004-07-11 18:19:43 +00:00
Andrey Hristov 7af08c0c34 fixing bug 29038:
EXTR_PREFIX_SAME is prevented from creating a new variable when the key
is a empty string. EXTR_PREFIX_ALL is also prevented from doing that,
but works for numbers.
2004-07-11 18:18:05 +00:00
Timm Friebe cd75bd4f65 - Initial release 2004-07-11 16:57:38 +00:00
Timm Friebe a14c66445a - Added simple test for float exceeding the float precision
# See bug #29064
2004-07-11 16:57:12 +00:00
Timm Friebe 1e6ccabd5f - Initial release 2004-07-11 16:31:32 +00:00
Timm Friebe d6c0fdfd2f - Initial release 2004-07-11 16:10:03 +00:00
Ilia Alshanetsky 4ebcb2ecfe Fixed bug #29008 (array_combine() does not handle non-numeric/string keys). 2004-07-11 15:23:57 +00:00
ed6ebf011b ChangeLog update 2004-07-11 00:33:01 +00:00
Jon Parise d46f8078f5 DragonFly BSD is derived from FreeBSD and requires the same floating point
precision fix.
2004-07-10 19:29:01 +00:00
Wez Furlong a0957e24b7 Fix #28402: no need for -ldl 2004-07-10 12:49:34 +00:00
Wez Furlong b52f7a01af Bump PHP 5 sqlite extension number to 2.0
(put some distance between it and the 4.3 version)
2004-07-10 12:30:18 +00:00
Wez Furlong e563b4eafa Upgrade bundled library to 2.8.14 + misc fixes
(http://www.sqlite.org/cvstrac/chngview?cn=1742)
2004-07-10 12:27:51 +00:00
Wez Furlong cd732f1a3f RIP: greedy ready problems
This allows people to use fread($fp, filesize($filename)) for regular files,
but packet-based non-greedy reads for everything else.
2004-07-10 10:54:09 +00:00
Andi Gutmans e5cfb1d05c - Better stability during premature shutdown of request startup 2004-07-10 07:46:17 +00:00
Ilia Alshanetsky 41b639fffe Fixed function proto. 2004-07-09 17:49:08 +00:00
69e20cf219 ChangeLog update 2004-07-09 00:33:24 +00:00
Ilia Alshanetsky 79c28f7618 Fixed bug #29049 (array sorting via user function/method does not validate
it).
2004-07-08 17:07:22 +00:00
Sergey Kartashoff c176a0ae20 - A bugfix in search words hilightling code (mnogosearch extension). 2004-07-08 05:22:14 +00:00
Ilia Alshanetsky f28b063c28 Last dangerous alloca() bits. 2004-07-08 01:18:43 +00:00
e080db4303 ChangeLog update 2004-07-08 00:32:27 +00:00
Edin Kadribasic 5e605e6dc2 Added memory-limit to the list of excluded force-on options 2004-07-07 12:25:10 +00:00
Georg Richter 9db1075c0e added check in config.m4 for deprecated library
added support for new 4.1.3-beta functions
	mysqli_stmt_field_count
	mysqli_stmt_attr_set
	mysqli_stmt_attr_get
removed support for deprecated/old api functions
fixed bug in constructor_get
2004-07-07 08:02:27 +00:00
1d89ed6ee3 ChangeLog update 2004-07-07 00:32:37 +00:00
Ilia Alshanetsky 5201e62d0d Fixed bug #29034 (wordwrap() returns a boolean when passed empty string). 2004-07-06 22:16:42 +00:00
Sergey Kartashoff c144fdf680 - Some fixes in mnogosearch extension 2004-07-06 19:08:45 +00:00
Marcus Boerger a2592aa5fb - Revert storing handle, got lost in 1.92, noticed by Kamesh Jayachandran
<kameshj at fastmail dot fm>
2004-07-06 18:48:39 +00:00
Ard Biesheuvel 1b4e0b81e3 Don't copy ini items to module globals
(fixed unregistered bug with mangled default_db setting)
2004-07-06 13:46:19 +00:00
Sebastian Bergmann b5aa8db6a3 Fix ZTS build. 2004-07-06 08:01:07 +00:00
Dmitry Stogov 8ad22e4279 Fixed bug #28751 (SoapServer does not call _autoload()) 2004-07-06 07:30:33 +00:00
ea5dc3d577 ChangeLog update 2004-07-06 00:33:32 +00:00
Ilia Alshanetsky 7f7f566318 Eliminate alloca() calls where they can be affected by the users. 2004-07-05 21:31:35 +00:00
Ilia Alshanetsky 2ba792cd0b Don't use alloca() where it can reached by the users. 2004-07-05 21:16:29 +00:00
Marcus Boerger c884ad017c - Bugfix: #29019 Database not closing 2004-07-05 19:36:10 +00:00
Andi Gutmans 82b4d74fd4 - Disable zend_mm for 5.0.0 2004-07-05 17:06:41 +00:00
Sascha Schumann f51ff68dfa - revert to proper behaviour 2004-07-05 11:41:31 +00:00
Moriyoshi Koizumi 8989a96789 - Add test for bug #28325. 2004-07-05 07:53:41 +00:00
447223f48a ChangeLog update 2004-07-05 00:32:17 +00:00
Ilia Alshanetsky d5fc8152f3 Eliminate potentially dangerous alloca(). 2004-07-04 17:13:58 +00:00
Ilia Alshanetsky a41a54f7fa Fixed bug #28963 (Missing space for \0 in address allocation). 2004-07-04 16:52:59 +00:00
Marcus Boerger c5b9577df8 Fix TSRM build 2004-07-04 11:14:17 +00:00
beb3674b7a ChangeLog update 2004-07-04 00:32:20 +00:00
Moriyoshi Koizumi 0f2c97f627 BFN 2004-07-03 16:14:46 +00:00
Moriyoshi Koizumi a92af73136 - Bugfix #28325 (circular reference serialisation). 2004-07-03 16:10:28 +00:00
ac3b484388 ChangeLog update 2004-07-03 00:32:18 +00:00
Andi Gutmans c3e9cd9c91 - Should fix mem leak with ZEND_MM. I made this change a while ago and
- rolled it back but I don't remember why. Please test!
2004-07-03 00:16:39 +00:00
ae5301c5d5 ChangeLog update 2004-07-02 00:32:17 +00:00
Ilia Alshanetsky 2ba0608e48 Do not use alloca() where it can be easily abused by the users.
# This probably should go into reflection code as well.
2004-07-01 16:28:32 +00:00
Sterling Hughes e8f984d77a fix bug wrt to CURLOPT_POSTFIELDS where if you passed it code like:
$fields = array('foo' => 'bar');
curl_setopt($ch, CURLOPT_POSTFIELDS, $fields);
curl_exec($ch);
as opposed to :

curl_setopt($ch, CURLOPT_POSTFIELDS, array('foo' => 'bar'));

you'll get a segv or no results, depending on the mood and cycle of the
moon.
2004-07-01 06:50:46 +00:00
Sara Golemon 76766f2d31 That hashtable should never have been an argument.... 2004-07-01 04:43:29 +00:00
d24e005477 ChangeLog update 2004-07-01 00:32:13 +00:00
Frank M. Kromann e0fe48e8a0 Fix for #28512. news entry 2004-06-30 19:51:28 +00:00
Frank M. Kromann 2067ce4079 Fix for #28512. Allocate enough space to store data 2004-06-30 19:46:57 +00:00
Ilia Alshanetsky bdfd8c60ea Another instance where alloca() is not needed. 2004-06-30 13:43:16 +00:00
Ard Biesheuvel 81dbc2fcef Fixed Ilia's alloca() issue/exploit
Removed pointless RINIT()
Use macros for consistent resource type names
2004-06-30 10:55:03 +00:00
Ilia Alshanetsky 690ca62dd3 Do not use alloca() where it can be abused through user input. 2004-06-30 01:12:06 +00:00
0850c7a348 ChangeLog update 2004-06-30 00:32:27 +00:00
Wez Furlong 8f435013ff Fix for Bug #28964 fread "greedy" behaviour 2004-06-29 21:51:53 +00:00
2aa678b088 ChangeLog update 2004-06-29 00:32:44 +00:00
Ilia Alshanetsky ed7d1e82c6 Removed pointless allocation check. 2004-06-28 22:31:28 +00:00
Sebastian Bergmann b163696106 Fix #28921 (Bad grammar in INSTALL). 2004-06-28 16:41:01 +00:00
Derick Rethans da2a1977b5 - Fixed bug with leap year checking. 2004-06-28 14:33:57 +00:00
Ard Biesheuvel 77804efa77 Revert at Derick's request 2004-06-28 11:41:08 +00:00
Ard Biesheuvel d1efeb2e58 BFN 2004-06-28 11:28:12 +00:00
Ard Biesheuvel 16e2d61435 MFB Fixed bug #28897 (-1 returned as -0.000 for 64-bit scaled int) 2004-06-28 11:27:05 +00:00
98672f41ba ChangeLog update 2004-06-28 00:33:21 +00:00
Ilia Alshanetsky 53bf5ccbea Removed unneeded if(). 2004-06-27 21:49:47 +00:00
Marcus Boerger 91f0369c80 Add more tests 2004-06-27 13:28:01 +00:00
Marcus Boerger 46e9abe602 Add more tests 2004-06-27 13:15:31 +00:00
99b5263afd ChangeLog update 2004-06-27 00:32:20 +00:00
Marcus Boerger 962b593455 BFN 2004-06-26 22:08:19 +00:00
Moriyoshi Koizumi d200a703e7 *** empty log message *** 2004-06-26 17:04:39 +00:00
Uwe Schindler 3bb7e73656 replace strncpy with strlcpy 2004-06-26 10:30:07 +00:00
Stefan Esser 59d55efb17 As long we pass values by reference this is needed. Ugly! 2004-06-26 08:09:28 +00:00
Stefan Esser ff716cbd3e Fixed input_filter functions need emalloc()ed values. 2004-06-26 07:57:37 +00:00
Stefan Esser 9e5ea7d229 strip_tags() news 2004-06-26 07:46:08 +00:00
Stefan Esser a27d5d842a IE we love you all... 2004-06-26 07:43:02 +00:00
Moriyoshi Koizumi 4eccf848ec - WS 2004-06-26 05:41:14 +00:00
Moriyoshi Koizumi b33f7ab671 - Fix bug #28466 (mbstring_convert_variables() problem). 2004-06-26 05:39:00 +00:00
f125cb60cc ChangeLog update 2004-06-26 00:32:25 +00:00
Edin Kadribasic 42f7b8026c MFB: Memory leak fix (patch by Joe Orton)
Fixes #28113. Adapted to php5 by Magnus Määttä.
2004-06-25 13:00:48 +00:00
Wez Furlong 5aa568254a export zend stream functions for zend extensions under windows 2004-06-25 12:55:11 +00:00
2f94546824 ChangeLog update 2004-06-25 00:32:18 +00:00
Sara Golemon a4032b68c6 Ease off on severity of new error (Using Resources as array offsets) 2004-06-24 16:35:34 +00:00
Ilia Alshanetsky e4e71fd8ba MFB: Fixed bug #1713 (possible crash inside tidy_get_error_buffer()). 2004-06-24 14:20:59 +00:00
Stefan Esser 476c9a3b3d Fixed zend_parse_parameters arguments... 2004-06-24 08:49:00 +00:00
Ilia Alshanetsky 81abbc66fc Added missing safe_mode & open_basedir checks. 2004-06-24 00:48:58 +00:00
ca14c9b1af ChangeLog update 2004-06-24 00:32:21 +00:00
Sara Golemon 56b153390b BugFix #28879 Inconsistent behavior between explicit and implicit array creation.
Changes:

Throw E_WARNING "Illegal offset type" when explicitly creating
array elements with objects, arrays, or resorces as indexes.
This matches implicit creation w/ obj/arr indices.

Throw E_WARNING "Resource ID#%ld used as offset, casting to integer (%ld)"
when implicitly creating array with resource as index. (BC)
2004-06-23 23:20:44 +00:00
George Schlossnagle 9e187415f9 fix for inheritability 2004-06-23 18:06:00 +00:00
Georg Richter f063bdec06 added php_mysqli_construct_get to support __construct in extended classes 2004-06-23 16:47:25 +00:00
Ard Biesheuvel dc701bfdab Changed name to all caps 2004-06-23 13:42:06 +00:00
Ard Biesheuvel 391cbac1f2 Return all results as strings until I can convince the other guys that
it should be otherwise
2004-06-23 13:26:09 +00:00
Ard Biesheuvel 18cd69ef74 Fixed some int-long issues 2004-06-23 13:20:54 +00:00
Uwe Schindler 8327d4e2bd Addendum to bug #28878: change ini keys as PHP_INI_SYSTEM
Also: Adding "bucket" parameter to non-ini-keys, Elemination of double CONTENT_TYPE/_LENGTH environment variables
2004-06-23 13:02:01 +00:00
Dmitry Stogov 2b216967f2 Added SOAP configuration directives 2004-06-23 08:18:42 +00:00
d632106e6e ChangeLog update 2004-06-23 00:32:34 +00:00
Andrei Zmievski 279770743f MFB (better error checking in pcre_fullinfo() calls). 2004-06-22 22:21:58 +00:00
Ilia Alshanetsky 869a90f015 Fixed possible buffer overflow. 2004-06-22 20:27:46 +00:00
Alex Leigh ef81373201 Updated the author's contact information. 2004-06-22 18:08:03 +00:00
Uwe Schindler e276023d82 Fix bug #28878: php.ini values in php5_execute 2004-06-22 15:37:40 +00:00
Dmitry Stogov 4ea8f4b9f2 BUGFIX: Segfault if server's URL has no path. ("http://192.168.8.1:180") 2004-06-22 12:42:17 +00:00
c055a54343 ChangeLog update 2004-06-22 00:32:17 +00:00
Ilia Alshanetsky a3bd8bcd7b Added missing safe_mode check. 2004-06-21 22:53:52 +00:00
Sara Golemon 8f2686df35 BFN 2004-06-21 21:09:13 +00:00
Sara Golemon a2c24ae90e BugFix#28868 (Part Two): This fixes thread unsafety in the userspace
filters which relates to the fix just applied for userspace wrappers.
2004-06-21 21:08:05 +00:00
Marcus Boerger dc66fb1f10 Fixed bug #28822: ArrayObject::offsetExists() works inverted 2004-06-21 19:15:27 +00:00
Sara Golemon 7fcfa8865e BugFix#28868: Wrapper hash not thread-safe.
Userdefined wrappers were being registered into a global wrapper hash
which can cross threads.  Termination of once instance then has the
potential to leave an active stream in another instance with no wrapper
leading to segfault.
2004-06-21 18:58:55 +00:00
Dmitry Stogov d9226a1dd0 Support for HTTP redirection. 2004-06-21 12:56:33 +00:00
Tomas V.V.Cox 1fb65c4c29 More output magic on nested exceptions 2004-06-21 04:36:17 +00:00
Tomas V.V.Cox 24ec6e5a5c Be more consistent with CS 2004-06-21 04:06:18 +00:00
Tomas V.V.Cox 8957eac122 Some API changes:
- addObserver() params order switched
- signal() -> _signal()
- public:getCauseMessage() -> private:_getCauseMessage()
- some more docs
2004-06-21 03:53:39 +00:00
907bdcbc7e ChangeLog update 2004-06-21 00:32:07 +00:00
Ilia Alshanetsky a99e4b5969 Removed unneeded checks around Zend allocation macros. 2004-06-20 21:40:43 +00:00
Tomas V.V.Cox d3de81fb00 First release of the PEAR_Exception class
(dedicated to otherbird)
2004-06-20 19:08:37 +00:00
Marcus Boerger 3df3aedbe0 BFN 2004-06-20 16:49:49 +00:00
Marcus Boerger de8b457181 Fix 2nd issue of bug #28831 2004-06-20 16:46:27 +00:00
Marcus Boerger 9219b746bb BFN 2004-06-20 09:39:09 +00:00
Marcus Boerger 43b4b086db Bugfix #28851: call_user_func_array has typo in error message 2004-06-20 09:37:35 +00:00
0e6607aa51 ChangeLog update 2004-06-20 00:32:22 +00:00
Jan Lehnardt 536e7448f6 - do it right (phpize path issue) 2004-06-19 20:32:07 +00:00
Jan Lehnardt f4f844af19 - phpize now can handle directories with spaces in their name (#28847) 2004-06-19 19:39:56 +00:00
Sebastian Bergmann f0903895c1 Reflection_* -> Reflection*. Patch by Timm Friebe. 2004-06-19 16:52:04 +00:00
8586e6505f ChangeLog update 2004-06-19 00:32:22 +00:00
Sara Golemon 2f7c5d30b5 Another typo in converting array index doubles to long. 2004-06-18 18:33:46 +00:00
George Schlossnagle 6cc2073d91 tests for the crash in bug 28213 2004-06-18 18:10:52 +00:00
George Schlossnagle 6d182a8456 fix for 28213.
class_name and call_type should be reinitialized on every loop iter.
2004-06-18 17:34:58 +00:00
Martin Jansen 6910e6432a * Replaced the nonexistent word "postfix" with "suffix". 2004-06-18 14:41:01 +00:00
Sara Golemon 851b6d4475 String lengths should never be char pointers. 2004-06-18 00:44:37 +00:00
Ilia Alshanetsky 0c72b185fd Fixed possible memory leak. 2004-06-18 00:44:35 +00:00
Ilia Alshanetsky cfbf5b24b7 Fixed bug #28818 (Apache 2 sapis do not export st_dev). 2004-06-18 00:36:58 +00:00
cf8a8a3189 ChangeLog update 2004-06-18 00:32:27 +00:00
Sara Golemon 96a8b63865 String length in parse_parameters should be int 2004-06-17 18:23:47 +00:00
ad2651a74a ChangeLog update 2004-06-17 00:32:34 +00:00
Ilia Alshanetsky 23d71171cf Properly handly high ascii values in soundex(). 2004-06-17 00:17:49 +00:00
Ard Biesheuvel 5232a5afea 64-bit bugsquash party 2004-06-16 23:57:25 +00:00
Stig Bakken 6527a454c6 * don't register object on destructors list if it does not define its
own emulated destructor
2004-06-16 16:26:12 +00:00
c9908cf81d ChangeLog update 2004-06-16 00:32:45 +00:00
Stefan Esser 585628ba67 Fixed: made 3rd parameter to strrpos 64bit safe. 2004-06-15 22:38:18 +00:00
Marcus Boerger 47c72816d3 BFN 2004-06-15 20:40:58 +00:00
Marcus Boerger 4fec06587b #28789: ReflectionProperty getValue() fails on public static members 2004-06-15 20:39:49 +00:00
Pierre Joye 0f5e09c192 - Fix #1602 (reported by Cox)
Do not display var=value using config-get (easy scripting)
2004-06-15 16:48:49 +00:00
Pierre Joye 98e59d58ba - Fix licence (#1645)
- update my status there, reflecting the fact for the past 11 months
2004-06-15 16:33:46 +00:00
Ard Biesheuvel 350e5aa862 Refactored statement allocation
Added emulated support for named input parameters
2004-06-15 14:16:22 +00:00
Rob Richards 196506caa1 BFN 2004-06-15 11:51:09 +00:00
Rob Richards 7c7c353b1e Fixed bug #28771 (Segfault when using xslt and clone)
Add test case for bug #28721
2004-06-15 11:50:56 +00:00
Ard Biesheuvel f91395898c Un-revert param index fix 2004-06-15 10:22:21 +00:00
Ard Biesheuvel e48d127244 Revert (at Wez's request) 2004-06-15 10:06:41 +00:00
313c153274 ChangeLog update 2004-06-15 00:32:13 +00:00
Antony Dovgal 0a896dd987 add tests 2004-06-14 20:10:27 +00:00
Antony Dovgal 73060a89ee fix config.m4
add fold markers
2004-06-14 19:58:35 +00:00
Marcus Boerger afc5a6145c Need {} here 2004-06-14 19:09:42 +00:00
Ard Biesheuvel 2cc63714a0 Added support for fetching and binding to blob fields 2004-06-14 10:56:49 +00:00
533cdf740f ChangeLog update 2004-06-14 00:32:15 +00:00
Ard Biesheuvel 2b21476207 Release isc statement handle when dtor is called
Don't separate() bound zvals
2004-06-13 23:24:31 +00:00
Ard Biesheuvel 1d7a4ed492 Report param binding error 2004-06-13 22:09:54 +00:00
Ilia Alshanetsky d26ddca966 Standardize error reporting. 2004-06-13 17:04:36 +00:00
Pierre Joye 495925381e - Typo (#1627) (cox) 2004-06-13 14:06:01 +00:00
Ard Biesheuvel cb4612c735 Added double param type 2004-06-13 10:35:01 +00:00
Rob Richards ac772dcf53 BFN 2004-06-13 10:13:12 +00:00
Rob Richards e73d498947 Fix bug #28721 (appendChild() and insertBefore() unset DOMText) 2004-06-13 10:12:47 +00:00
7fefbbb177 ChangeLog update 2004-06-13 00:32:14 +00:00
Ard Biesheuvel e1519d6f17 GCC fixes 2004-06-12 22:17:16 +00:00
Ard Biesheuvel c84c5640e7 Revert 2004-06-12 20:52:07 +00:00
Ard Biesheuvel 6b3cda310a Added client/server info attributes 2004-06-12 18:56:07 +00:00
Ard Biesheuvel 8a3975191e Hope I finally got it right this time 2004-06-12 18:42:13 +00:00
Ard Biesheuvel a312bb5ee3 Folding markers 2004-06-12 17:09:33 +00:00
Ard Biesheuvel ad568aab6f Improved error handling
Added some comments
2004-06-12 16:58:20 +00:00
Ard Biesheuvel c8c0ddb73d Removed dependency on regular interbase extension
Added support for all datatypes except BLOBs
2004-06-12 16:07:52 +00:00
Ard Biesheuvel 1fb48b5091 Removed dependency on regular interbase extension 2004-06-12 16:05:49 +00:00
Ard Biesheuvel 216c8ffdcd Use snaps. LIB path 2004-06-12 14:59:45 +00:00
Ard Biesheuvel 15fa07f0f6 Changed LIB path 2004-06-12 10:23:31 +00:00
Greg Beaver 22fa023c88 fix bug #1610: pear package doesn't validate deps
It was never validating deps at all!
2004-06-12 06:15:55 +00:00
Greg Beaver 9873fa5e42 fix bug #1615: installer must create extension dir if it doesn't exist, patch by Tomas 2004-06-12 05:48:10 +00:00
Greg Beaver 37b73ad2d4 fix bug #1617, exception never returned from PEAR_ErrorStack->push() 2004-06-12 05:36:40 +00:00
Ard Biesheuvel c29704e066 New test 2004-06-12 03:11:16 +00:00
Ard Biesheuvel 493b89c3b1 Nearly complete implementation
No date/time fields yet ...
2004-06-12 03:09:48 +00:00
Ard Biesheuvel 39a690321a Added export macros 2004-06-12 02:49:47 +00:00
Ard Biesheuvel 50ac5db2b4 Added double param type
Added param struct initialiser
Reversed param parsing order (long <=> string)
2004-06-12 02:35:34 +00:00
Ard Biesheuvel 1e3854597c Initial revision (incomplete) 2004-06-11 01:37:06 +00:00
d0c4b3d3ec ChangeLog update 2004-06-11 00:34:13 +00:00
Ilia Alshanetsky b9fc9a6ad1 hypot() is not experimental. 2004-06-10 19:38:24 +00:00
Ilia Alshanetsky af5501027f Fixed bug #28723 (Fixed mbstring config.m4 to work on OSes where test
command does not support -e parameter).
2004-06-10 14:06:17 +00:00
Marcus Boerger 7318238236 Changed that a bit 2004-06-10 13:39:30 +00:00
Marcus Boerger 4da11644de - Require a single white-space char after /** to start a doc comment that
way we prevent /*** from becoming a doc comment (as requested Derick).
2004-06-10 13:38:31 +00:00
Marcus Boerger c756609658 Add missing declaration 2004-06-10 12:32:09 +00:00
Marcus Boerger eb0cb6f6ed Small code layout change 2004-06-10 12:11:16 +00:00
Marcus Boerger 2784cf206d BFN 2004-06-10 11:57:04 +00:00
Marcus Boerger eefdd0ea49 Do not require NEWLINE at start of doccomment 2004-06-10 11:40:34 +00:00
Marcus Boerger 17a363a8f8 BFN 2004-06-10 11:29:15 +00:00
Marcus Boerger e8e4ff0aa1 Bugfix #28699: Reflection api bugs 2004-06-10 11:28:29 +00:00
Dmitry Stogov 0282ad792a Fixed bug #28702 (SOAP does not parse WSDL service address correctly). 2004-06-10 09:07:09 +00:00
622f7679f7 ChangeLog update 2004-06-10 00:32:42 +00:00
Frank M. Kromann 36702d5f41 Allow compilation on Win32.
Need to implement a few Windows specific functions.
2004-06-09 19:27:36 +00:00
Marcus Boerger bd05792560 BFN 2004-06-09 19:26:55 +00:00
Marcus Boerger 4213153365 Fix Bug #28694 ReflectionExtension::getFunctions() crashes PHP 2004-06-09 19:25:42 +00:00
Ilia Alshanetsky f0ffe7c85b Fixed bug #28175 (Allow bundled GD to compile against freetype 2.1.2). 2004-06-09 14:50:05 +00:00
Ilia Alshanetsky 3e638c84c0 Fixed bug #28525 (gmp_powm() does not work with hexadecimal string modulo
represented as a string).
Patch by: pickett at sumu dot org
2004-06-09 14:39:33 +00:00
Ilia Alshanetsky ccc580f408 Fixed memory leak on error in win32's opendir() emulation. (Patch by Wez) 2004-06-09 14:18:14 +00:00
1f73efcaab ChangeLog update 2004-06-09 00:32:35 +00:00
Ard Biesheuvel 4713ce294d Interbase news 2004-06-08 20:25:49 +00:00
Greg Beaver 1f20b7a626 partial fix, bug #1163: rpm build doesn't build properly 2004-06-08 18:26:20 +00:00
Greg Beaver d14e259823 fix bug #1550: Builder does not set path to match bin_dir 2004-06-08 18:15:11 +00:00
Greg Beaver 29a09f984c fix bug #1378: user/pass must be urldecoded from parse_url in Remote.php 2004-06-08 18:03:46 +00:00
Greg Beaver 628e5530b9 fix bug #1153: PEAR command doesn't work after upgrading
reverting earlier fix - people must have register_argc_argv=on set in php.ini for PEAR to work.
2004-06-08 17:56:22 +00:00
Greg Beaver b175cdfd71 fix bug #1581: unhelpful error message if "pear blatch" is typed 2004-06-08 17:49:19 +00:00
Ilia Alshanetsky 49fb6260b6 Fixed bug #1580 (Tidy configuration settings leak memory). 2004-06-08 14:55:14 +00:00
Ilia Alshanetsky b8c9e83664 Fixed bug #28692 (\0 in Authenticate header passed via safe_mode). 2004-06-08 13:23:38 +00:00
Ard Biesheuvel 4ea43fe019 ... back from the dead 2004-06-08 10:04:09 +00:00
Georg Richter 202d2990a9 fixed crash (changed MYSQL TO MY_MYSQL in mysql_stmt_init) 2004-06-08 06:20:58 +00:00
3fc91aff97 ChangeLog update 2004-06-08 00:32:15 +00:00
Andi Gutmans 0bdbbd379e - Go back to -dev (Shouldn't need another RC) 2004-06-07 18:57:34 +00:00
Ilia Alshanetsky ceb70dbc68 Fixed bug #28668 (glob() does not work with relative paths on Windows). 2004-06-07 18:30:16 +00:00
Frank M. Kromann f05924db37 Fix build on win32 2004-06-07 18:03:51 +00:00
Andi Gutmans 6f47156228 - Roll RC3 2004-06-07 14:23:45 +00:00
Ilia Alshanetsky ff5b2d27ae Fixed bug #28670 (WWW-Authentication header mangling with PCRE in safe_mode
adds extra spaces).
2004-06-07 13:51:50 +00:00
Georg Richter 1b40042b35 forgot to remove Win32 restrictions for mysql methods 2004-06-07 08:34:52 +00:00
Derick Rethans bcca5b8cb5 - Reorder (again :) 2004-06-07 07:05:33 +00:00
Sara Golemon 3838fb99de MFB: Missing length limit parameter. 2004-06-07 05:00:37 +00:00
1b80f44cf1 ChangeLog update 2004-06-07 00:32:20 +00:00
Pierre Joye d7e86a5669 - No more Pager 2004-06-06 22:49:46 +00:00
Pierre Joye 8217b64a33 - Update for 5.0RC3 2004-06-06 22:49:10 +00:00
Ilia Alshanetsky 9c1e668593 Fixed bug #28649 (Proper glob() return value on Linux when there are no
matches).
2004-06-06 16:21:11 +00:00
Greg Beaver b4ae74ae2c update unit tests for PEAR 1.4.0dev6, using new getDownloadURL() xml-rpc call 2004-06-06 16:05:30 +00:00
Greg Beaver 9304645cf3 add missing $tmp to PEAR::isError() 2004-06-06 15:52:41 +00:00
Greg Beaver 84d9651b61 eliminate the annoyance of upgrading from crapster versions of PEAR once and for all.
Now, if getopt2 exists, it is used, otherwise getopt is used.
2004-06-06 15:04:16 +00:00
Georg Richter f0468116c0 removed conditional defines for load_data_infile_handlers on windows
(4.1.2 windows build is fixed now on mysql.com)
2004-06-06 08:52:19 +00:00
Stefan Esser fb5cb59035 Fixed Zend Function Destructor to use correct TSRM handle. 2004-06-06 08:37:12 +00:00
Sebastian Bergmann 14deb9dd04 ZTS fixes. 2004-06-06 06:40:19 +00:00
ff5fca9aa0 ChangeLog update 2004-06-06 00:33:20 +00:00
Georg Richter 216eb9f82b added mysqli changes 2004-06-05 18:43:31 +00:00
Georg Richter 93bf6517df Major changes for 4.1.2-alpha/4.1.3-beta:
- added container for mysql structure
- added load data infile callback functions (currently disabled under win)
Bug fixes:
- fixed property changes (4.1.1 -> 4.1.2)
- fixed memleak in mysqli_connect
- fixed bug #28100
- fixed bug #28205
- fixed bug #28430
2004-06-05 18:31:56 +00:00
Marcus Boerger 120625548d BFN 2004-06-05 14:59:32 +00:00
Marcus Boerger a6276a2414 Fix #28641: Instance of Interface 2004-06-05 14:59:21 +00:00
Ard Biesheuvel 9579de34d7 Added support for date/time types
Added support for compiling/executing PHP code stored in the database
Added support for TSRM
2004-06-05 10:03:42 +00:00
85c9a200fa ChangeLog update 2004-06-05 00:32:05 +00:00
Ard Biesheuvel 2c97bc2632 Fixed unregistered bug [crash in http_build_query()] 2004-06-04 16:54:14 +00:00
Ilia Alshanetsky f9cec029c8 Fixed bug #28632 (Prevent open_basedir bypass in MySQL's LOAD DATA LOCAL). 2004-06-04 15:26:54 +00:00
Ard Biesheuvel a37ffd814d Added support for scaled integers 2004-06-04 14:26:33 +00:00
Ilia Alshanetsky 0e443166e0 Fixed bug #28627 (When multiple MySQL links are used default link is
leaked).
Patch by: gavin at ipalsoftware dot com
2004-06-04 13:49:31 +00:00
Ard Biesheuvel f1a4a14ccb Added support for arbitrary input types
Added support for NULL input/output values
2004-06-04 13:33:56 +00:00
Sara Golemon ceb73ca019 MFB BugFix# 28626 You can't #ifdef check a typedef. Just give it another name since it's only used once anyway. 2004-06-04 01:03:38 +00:00
89ee6b45ad ChangeLog update 2004-06-04 00:34:01 +00:00
Ard Biesheuvel f4777d14e3 Let DB handle type coercion instead of PHP 2004-06-03 23:18:36 +00:00
Ard Biesheuvel 0223de2c39 Added support for other return types besides VARCHAR 2004-06-03 15:31:17 +00:00
Ard Biesheuvel 38030dac08 Fixed blob ID format 2004-06-03 12:00:23 +00:00
Ard Biesheuvel 5be358667b news 2004-06-03 10:55:27 +00:00
Andi Gutmans 02032ccf9f - Prepare for RC3RC2 2004-06-03 08:17:15 +00:00
40b17e6c5c ChangeLog update 2004-06-03 03:03:17 +00:00
Ard Biesheuvel bf4af0f4ca Ton of fixes 2004-06-02 21:43:31 +00:00
Ard Biesheuvel 86aecbbe31 Initial revision of PHP/Interbase UDF lib
# This will allow users running the embedded engine
# to call PHP functions from inside their SQL statements
2004-06-02 21:15:27 +00:00
Andi Gutmans f7ca8821b2 - Don't use ZEND_MM in Windows 2004-06-02 15:05:10 +00:00
Stanislav Malyshev 176f6d8e6e fix incdec - make value's refcount non-zero when passing to
write_property - otherwise __set caller cleanup could kill it.
2004-06-02 12:48:19 +00:00
c59be44de1 ChangeLog update 2004-06-02 00:32:03 +00:00
Ard Biesheuvel 39edbe5192 Don't be too strict if the number of binding arguments provided exceeds the expected number 2004-06-01 23:31:43 +00:00
Ilia Alshanetsky 6b35037ca2 No need to NULL terminate manually, snprintf() does it for us already. 2004-06-01 21:04:33 +00:00
Ilia Alshanetsky 98a6986d97 Fixed bug #28597 (xmlrpc_encode_request() incorrectly encodes chars in
200-210 range).
Patch by: fernando dot nemec at folha dot com dot br
2004-06-01 20:16:06 +00:00
Ilia Alshanetsky db9f1fafa5 Fixed leak inside MINFO function.
Fixed crash inside enchant_dict_suggest() when there are no suggestions.
Added missing safe_mode/open_basedir check inside
enchant_broker_request_pwl_dict().
Fixed various function prototypes.
2004-06-01 18:59:49 +00:00
Ard Biesheuvel b027552ca3 Removed debugging code 2004-06-01 17:14:47 +00:00
Greg Beaver 5b565c1eb1 update dependency to PEAR 1.4.0dev5 2004-06-01 14:51:49 +00:00
Greg Beaver 27a4b575e8 test files for PEAR are now installable! 2004-06-01 14:29:59 +00:00
Greg Beaver cb0b01f7c2 file needed for registry test 2004-06-01 14:27:54 +00:00
Greg Beaver a0ebaab052 add needed package.xml files for channel tests 2004-06-01 14:15:41 +00:00
Greg Beaver e78e1dd5e8 update to include all new unit tests and files 2004-06-01 13:55:49 +00:00
Greg Beaver 58483c8776 begin work on making the tests installable 2004-06-01 13:45:55 +00:00
Greg Beaver 472de86f8d prepare for actual installable unit tests 2004-06-01 13:22:28 +00:00
Greg Beaver 86953ab0f5 fix unit tests for 1.4.0dev4 2004-06-01 13:11:15 +00:00
Derick Rethans 0ede231c76 - Reorder 2004-06-01 11:54:00 +00:00
Andi Gutmans 6f34d891f5 - NEWS 2004-06-01 11:47:14 +00:00
Andi Gutmans 2e19f82a7f - If user error handler returns "false" then we relay to the built in error
handler
2004-06-01 11:45:46 +00:00
Ard Biesheuvel ff3a363d7a Use constant IBASE_CREATE instead of just 0 2004-06-01 08:38:33 +00:00
Ard Biesheuvel 302fd9a77f Woops, missed one 2004-06-01 00:50:05 +00:00
Ard Biesheuvel 5a8a9a59e2 Fixed bug #28569 (connection id is not thread safe) 2004-06-01 00:44:20 +00:00
95910aa26c ChangeLog update 2004-06-01 00:32:37 +00:00
Marcus Boerger 9b8eee74d9 Refcount must not be set separatley again. 2004-05-31 21:49:52 +00:00
Marcus Boerger 20b60f49d9 Add missing initialization 2004-05-31 21:46:00 +00:00
Marcus Boerger 21315c08b7 Add missing initialization 2004-05-31 21:43:43 +00:00
Marcus Boerger 374ac86e33 #28589: Segfault in Reflection API 2004-05-31 21:38:01 +00:00
Pierre Joye f6354c3a1a MFB: missing ';' 2004-05-31 21:04:21 +00:00
Ilia Alshanetsky 9e970ef9a8 Added missing argument check. 2004-05-31 21:01:29 +00:00
Ilia Alshanetsky 22dfb88bf1 Fix build. 2004-05-31 20:25:37 +00:00
Ard Biesheuvel 3be22062fa Fix typo in error message 2004-05-31 13:43:06 +00:00
Ard Biesheuvel e9125d6338 Improved handling of 'CREATE DATABASE ...' by ibase_query()
Improved param handling of ibase_query() and ibase_execute()
2004-05-31 13:40:25 +00:00
Rob Richards 5b0f34ae80 Fix bug #28584: DOMText::splitText() does not split text properly (benjcarson)
Prototype fixes
2004-05-31 12:50:28 +00:00
Zeev Suraski 7d04465b74 Fix prototypes 2004-05-31 12:27:49 +00:00
Rob Richards 1d82c42493 fix leak when using relaxng
interim fix for isolating our streams handling
- once libxml supports overriding streams this should be changed
  for security reasons
2004-05-31 11:20:46 +00:00
Zeev Suraski 846c5a252e Fix typo 2004-05-31 08:58:32 +00:00
468ae7b88a ChangeLog update 2004-05-31 00:33:13 +00:00
Brad House cae0fd23f0 Update the mcve module for libmonetra 4.0
A compatability layer has been introduced which should mean all
scripts written for v 3.2 of the module should continue working,
as well as compilation should still work against libmcve 3.2.x.
This module eventually needs to be renamed to 'monetra' to reflect
the naming change of the underlying library.
2004-05-30 22:41:24 +00:00
Ard Biesheuvel fda04a0ed3 Restrict 'CREATE DATABASE' in sql safe mode 2004-05-30 20:40:36 +00:00
Ard Biesheuvel 17da85ba9b Fix Win32 build
Added missing 'break'
2004-05-30 20:24:46 +00:00
Ilia Alshanetsky 4a7962b31f Fixed memory leak on ifx_error(). 2004-05-30 18:58:47 +00:00
Ilia Alshanetsky 33d72ede4e Fixed bug #28564 (Problem building informix as a shared extension).
Patch by: roques at mti dot ag
2004-05-30 17:56:52 +00:00
Zeev Suraski a2ea2d7173 Fix prototypes 2004-05-30 17:53:12 +00:00
Ard Biesheuvel 18fa78842d Fix unregistered bug (segfault on uninitialised pointer)
Return string("0 ") from ibase_query() if query succeeded but did not affect any rows
2004-05-30 17:51:19 +00:00
Zeev Suraski e54165e406 No meaning for unsigned 2004-05-30 17:34:11 +00:00
Zeev Suraski e11b518c95 Fix prototype 2004-05-30 17:32:32 +00:00
Greg Beaver 2e7e8f30fc fix unit tests for 1.4.0dev3 2004-05-30 17:02:34 +00:00
Ard Biesheuvel f7ce70672c Use default character set in generated test DB 2004-05-30 16:59:43 +00:00
Ard Biesheuvel bd2ddd9fae Fix HTML/table layout in info() entry 2004-05-30 16:41:28 +00:00
Ard Biesheuvel 56ca01da1f Removed ibase_timefmt() - use ini_set() instead
Improved phpinfo() appearance
2004-05-30 16:20:25 +00:00
Zeev Suraski 8b861ec798 Update to PHP-style prototypes
(a PHP function returning char *?  What were you smoking? :)
2004-05-30 15:12:08 +00:00
Brad House 43db887482 manually check for egrep 2004-05-30 14:33:45 +00:00
39729083ee ChangeLog update 2004-05-30 00:32:48 +00:00
Wez Furlong bd818c0118 Turn this off then 2004-05-29 09:27:18 +00:00
Greg Beaver a865b5d0c7 testing file 2004-05-29 09:21:31 +00:00
Greg Beaver 09ee88f9bf modify php_dump.php, .cvsignore ignores *.php
move include to the place where it is used
2004-05-29 09:09:46 +00:00
Greg Beaver 71e0c354ff update _installFile() test for channels 2004-05-29 09:06:09 +00:00
Greg Beaver 32fd0f3ffa update checkDeps/extractDownloadFilename tests for channels 2004-05-29 09:03:43 +00:00
Greg Beaver 478aff5c22 update registry test for channels 2004-05-29 09:02:47 +00:00
Greg Beaver 73124c04be use fake pearweb - now anyone can run the download unit tests.
These tests require channels to pass
2004-05-29 09:02:26 +00:00
Greg Beaver d4070174d8 fake pearweb package files, for unit testing downloads without an installed pearweb 2004-05-29 09:00:52 +00:00
Greg Beaver d87e221f44 config unit tests, ready for channels 2004-05-29 08:59:26 +00:00
Greg Beaver 918d45198a new unit tests
pearweb mock object is complete
2004-05-29 08:51:59 +00:00
Greg Beaver 8c5c17c3a1 update for conflicting file test 2004-05-29 08:49:01 +00:00
Greg Beaver 1f31e7ddea new package.xml needed to test conflicting files error 2004-05-29 08:48:01 +00:00
ba2b5623c3 ChangeLog update 2004-05-29 00:32:22 +00:00
Wez Furlong 7171429f21 Don't rely on TIOCNOTTY. 2004-05-29 00:30:11 +00:00
Ard Biesheuvel 5f53ee1537 Changed default date format to ISO
Enable sync flag in connect()
2004-05-28 23:39:33 +00:00
John Coggeshall 6b02a01c20 'tidy' should not be final, but 'tidyNode' should be. 2004-05-28 20:32:52 +00:00
Ard Biesheuvel 850c6a27f6 Fix commit/rollback of multi-link transactions
Some CS
2004-05-28 20:11:34 +00:00
Andrei Zmievski 915a990330 Allow user-defined error handlers to indicate whether default error
handler should be re-invoked, by returning true or false.
2004-05-28 17:28:33 +00:00
Ilia Alshanetsky 6544f8d47e Fixed memory leak on error. 2004-05-28 14:17:46 +00:00
Ilia Alshanetsky e389e255e6 The engine will take care out-of-memory situation for us. 2004-05-28 14:14:26 +00:00
Stefan Esser 23813d603c Fixed off-by-one in http_fopen_wrapper 2004-05-28 13:38:06 +00:00
Wez Furlong 54bbe548fe Hopefully resolve proc_open build issues.
If we need anything more elaborate than this, then we can move to a configure
time check as Sascha suggests.
2004-05-28 13:25:51 +00:00
Christian Stocker c59471cd1f fix memleak in php callbacks 2004-05-28 13:04:19 +00:00
Stefan Esser 2e3b9ec278 Fixed off-by-one in php_parse_url. 2004-05-28 11:33:23 +00:00
Derick Rethans 27344aaed6 - Added date/time parser thingy. 2004-05-28 10:47:15 +00:00
Derick Rethans f964cc09d2 - Fixed ip2long() behavior if an invalid IP address was passed to the
function. This makes it possible to distingiush between "255.255.255.255"
  and a wrong one.
2004-05-28 10:45:18 +00:00
Marcus Boerger 9797f49466 Add more outstanding patches 2004-05-28 09:14:44 +00:00
Marcus Boerger 0aceba0a8d Remove finished tasks 2004-05-28 09:12:07 +00:00
Marcus Boerger a8ced60e04 Remove finished tasks 2004-05-28 09:06:56 +00:00
Marcus Boerger 9d76829963 Add more things 2004-05-28 09:03:00 +00:00
Marcus Boerger 0ef420a71e Prevent possible problems with illegal properties 2004-05-28 08:55:10 +00:00
Derick Rethans 877ecb3c81 - Make the default mask for user defined error handlers include ALL errors,
including E_STRICT.
2004-05-28 08:08:56 +00:00
7489718769 ChangeLog update 2004-05-28 00:31:45 +00:00
Ilia Alshanetsky df71910d0e Better skip condition check for session tests. 2004-05-27 20:53:26 +00:00
Andrei Zmievski 844e7eb945 5.1 tasks. 2004-05-27 16:22:47 +00:00
Andi Gutmans e51105c6a6 - Back to RC3-dev until we roll final 2004-05-27 15:03:46 +00:00
739 changed files with 37713 additions and 27816 deletions

No files matched your search

+2127
View File
File diff suppressed because it is too large. Load diff
+2 -2
View File
@@ -220,7 +220,7 @@ COMMENT: Using the new OCI8 driver is encouraged where possible.
EXTENSION: dom
PRIMARY MAINTAINER: Christian Stocker <chregu@php.net>, Rob Richards <rrichards@php.net>, Marcus Boerger <helly@php.net>
MAINTENANCE: Maintained
STATUS: Experimental
STATUS: Working
SINCE: 5.0
-------------------------------------------------------------------------------
EXTENSION: simplexml
@@ -247,7 +247,7 @@ STATUS: Experimental
EXTENSION: xsl
PRIMARY MAINTAINER: Christian Stocker <chregu@php.net>, Rob Richards <rrichards@php.net>
MAINTENANCE: Maintained
STATUS: Experimental
STATUS: Working
SINCE: 5.0
-------------------------------------------------------------------------------
+1483 -380
View File
File diff suppressed because it is too large. Load diff
+247 -2
View File
@@ -1,15 +1,259 @@
PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
27 May 2004, PHP 5 Release Candidate 3
09 Dec 2004, PHP 5.0.3RC2
- Fixed bug #31034 (Problem with non-existing iconv header file). (Derick)
- Fixed bug #28598 (Lost support for MS Symbol fonts). (Pierre)
29 Nov 2004, PHP 5.0.3RC1
- Added the %F modifier to *printf to render a non-locale-aware representation
of a float with the . as decimal seperator. (Derick)
- Fixed error handling in mysqli_multi_query. (Georg)
- Extended the functionality of is_subclass_of() to accept either a class name
or an object as first parameter. (Andrey)
- Fixed potential problems with unserializing invalid serialize data. (Marcus)
- Fixed bug #30995 (snmp extension does not build with net-snmp 5.2). (Ilia)
- Fixed bug #30990 (allow popen() on *NIX to accept 'b' flag). (Ilia)
- Fixed bug #30967 (properties in extended mysqli classes don't work). (Georg)
- Fixed bug #30928 (When Using WSDL, SoapServer doesn't handle private or
protected properties). (Dmitry)
- Fixed bug #30922 (reflective functions crash PHP when interfaces extend
themselves). (Tony, Dmitry)
- Fixed bug #30904 (segfault when recording soapclient into session). (Tony,
Dmitry)
- Fixed bug #30890 (MySQLi testsuite)
- Fixed bug #30856 (ReflectionClass::getStaticProperties segfaults). (Marcus)
- Fixed bug #30832 ("!" stripped off comments in xml parser). (Rob)
- Fixed bug #30799 (SoapServer doesn't handle private or protected properties).
(Dmitry)
- Fixed bug #30783 (Apache crash when using ReflectionFunction::
getStaticVariables()). (Marcus)
- Fixed bug #30750 (Meaningful error message when upload directory is not
accessible). (Ilia)
- Fixed bug #30685 (Malformed SOAPClient http header reequest). (Dmitry)
- Fixed bug #30672 (Problem handling exif data in jpeg images at unusual
places). (Marcus)
- Fixed bug #30658 (Ensure that temporary files created by GD are removed).
(Ilia)
- Fixed bug #30645 (def. multi result set support for mysql_connect). (Georg)
- Fixed bug #30637 (compile with pear error). (Antony)
- Fixed bug #30587 (array_multisort doesn't separate zvals before
changing them). (Tony)
- Fixed bug #30572 (crash when comparing SimpleXML attribute to a boolean).
(Andi)
- Fixed bug #30566 (attribute namespace URIs are inconsistent when parsing).
(Rob)
- Fixed bug #30490 (PEAR installation fails). (Antony)
- Fixed bug #30475 (curl_getinfo() may crash in some situations). (Ilia)
- Fixed bug #30442 (segfault when parsing ?getvariable[][ ). (Tony)
- Fixed bug #30388 (rename across filesystems loses ownership and
permission info). (Tony)
- Fixed bug #30387 (stream_socket_client async connect was broken).
(vnegrier at esds dot com, Wez).
- Fixed bug #30381 (Strange results with get_class_vars()). (Marcus)
- Fixed bug #30375 (cal_info() does not work without a parameter). (Ilia)
- Fixed bug #30362 (stream_get_line() not handling end string correctly).
(Ilia)
- Fixed bug #30359 (SOAP client requests have no port in "Host" field).
(Dmitry)
- Fixed bug #30356 (str_ireplace() does not work on all strings). (Ilia)
- Fixed bug #30344 (Reflection::getModifierNames() returns too long strings).
(Marcus)
- Fixed bug #30329 (Error Fetching http body, No Content-Length, connection
closed or chunked data). (Dmitry)
- Fixed bug #30282 (segfault when using unknown/unsupported
session.save_handler and/or session.serialize_handler). (Tony)
- Fixed bug #30281 (Prevent non-wbmp images from being detected as such).
(Ilia)
- Fixed bug #30276 (Possible crash in ctype_digit on large numbers). (Ilia)
- Fixed bug #30230 (exception handler not working with objects). (Marcus)
- Fixed bug #30224 (Sybase date strings are sometimes not null terminated).
(Ilia)
- Fixed bug #30175 (SOAP results aren't parsed correctly). (Dmitry)
- Fixed bug #30147 (OO sqlite_fetch_object did not reset error handler). (Wez)
- Fixed bug #30133 (get_current_user() crashes on Windows). (Edin)
- Fixed bug #30061 (xml_set_start_namespace_decl_handler not called). (Rob)
- Fixed bug #30057 (did not detect IPV6 on FreeBSD 4.1). (Wez)
- Fixed bug #30042 (strtotime does not use second param). (Derick)
- Fixed bug #30027 (Possible crash inside ftp_get()).
(cfield at affinitysolutions dot com)
- Fixed bug #29954 (array_reduce segfaults when initial value is array). (Tony)
- Fixed bug #29883 (isset gives invalid values on strings). (Tony, Dmitry)
- Fixed bug #29801 (Set limit on the size of mmapable data). (Ilia)
- Fixed bug #29557 (strtotime error). (Derick)
- Fixed bug #29418 (double free when openssl_csr_new fails).
(Kamesh Jayachandran).
- Fixed bug #29385 (Soapserver always uses std class). (David, Dmitry)
- Fixed bug #29211 (SoapClient doesn't request wsdl through proxy). (Rob)
- Fixed bug #28817 (Var problem when extending domDocument). (Georg)
- Fixed bug #28599 (strtotime fails with zero base time). (Derick)
- Fixed bug #28220 (mb_strwidth() returns wrong width values for some hangul
characters). (Moriyoshi)
- Fixed bug #28209 (strtotime("now")). (Derick)
- Fixed bug #27798 (private / protected variables not exposed by
get_object_vars() inside class). (Marcus)
- Fixed bug #27183 (Userland stream wrapper segfaults on stream_write).
(Christian)
23 Sep 2004, PHP 5.0.2
- Added new boolean (fourth) parameter to array_slice() that turns on the
preservation of keys in the returned array. (Derick)
- Added the sorting flag SORT_LOCALE_STRING to the sort() functions which makes
them sort based on the current locale. (Derick)
- Added interface_exists() and make class_exists() only return true for real
classes. (Andrey)
- Added PHP_EOL constant that contains the OS way of representing newlines.
(Paul Hudson, Derick)
- Implemented periodic PCRE compiled regexp cache cleanup, to avoid memory
exhaustion. (Andrei)
- Renamed SoapClient->__call() to SoapClinet->__soapCall(). (Dmitry)
- Fixed bug with raw_post_data not getting set (Brian)
- Fixed a file-descriptor leak with phpinfo() and other 'special' URLs (Zeev)
- Fixed bug #30209 (ReflectionClass::getMethod() lowercases attribute).
(Marcus)
- Fixed bug #30182 (SOAP module processing WSDL file dumps core). (Dmitry)
- Fixed bug #30045 (Cannot pass big integers (> 2147483647) in SOAP requests).
(Dmitry)
- Fixed bug #29985 (unserialize()/ __PHP_Incomplete_class does not report
correctly class name). (Marcus, Tony)
- Fixed bug #29945 (simplexml_load_file URL limitation 255 char). (Rob)
- Fixed bug #29873 (No defines around pcntl_*priority definitions). (Derick)
- Fixed bug #29844 (SOAP doesn't return the result of a valid SOAP request).
(Dmitry)
- Fixed bug #29842 (soapclient return null value). (Dmitry)
- Fixed bug #29839 (incorrect convert (xml:lang to lang)). (Dmitry)
- Fixed bug #29830 (SoapServer::setClass() should not export non-public
methods). (Dmitry)
- Fixed bug #29828 (Interfaces no longer work). (Marcus)
- Fixed bug #29821 (Fixed possible crashes in convert_uudecode() on invalid
data). (Ilia)
- Fixed bug #29808 (array_count_values() breaks with numeric strings). (Ilia)
- Fixed bug #29805 (HTTP Authentication Issues). (Uwe Schindler)
- Fixed bug #29795 (SegFault with Soap and Amazon's Web Services). (Dmitry)
- Fixed bug #29737 (ip2long should return -1 if IP is 255.255.255.255 and FALSE
on error). (Tony)
- Fixed bug #29711 (Changed ext/xml to default to UTF-8 output). (Rob)
- Fixed bug #29678 (opendir() with ftp:// wrapper segfaults if path does not
have trailing slash). (Ilia)
- Fixed bug #29657 (xml_* functions throw non descriptive error).
(Christian, Rob)
- Fixed bug #29656 (segfault on result and statement properties). (Georg)
- Fixed bug #29566 (foreach/string handling strangeness (crash)). (Dmitry)
- Fixed bug #29447 (Reflection API issues). (Marcus)
- Fixed bug #29296 (Added sslv2 and sslv3 transports). (Wez)
- Fixed bug #29283 (Invalid statement handle in mysqli on execute). (Georg)
- Fixed bug #29913 (parse_url() is now binary safe). (Ilia)
- Fixed bug #27994 (segfault with Soapserver when WSDL-Cache is enabled).
(Dmitry)
- Fixed bug #27791 (Apache 2.0 SAPI build against Apache 2 HEAD). (Joe Orton,
Derick)
- Fixed bug #26737 (private/protected properties not serialized when user
declared method __sleep() exists). E_NOTICE thrown when __sleep() returns
name of non-existing member. (Andrey, Curt)
12 Aug 2004, PHP 5.0.1
- Changed destructor mechanism so that destructors are called prior to request
shutdown. (Marcus)
- Rewritten UNIX and Windows install help files. (Documentation Team)
- Updated several libraries bundled with the windows release which now
includes libxml2-2.6.11, libxslt-1.1.7 and iconv-1.9.1. (Rob, Edin)
- Improved and moved ActiveScript SAPI to PECL. (Wez)
- Fixed bug #29606 (php_strip_whitespace() prints to stdout rather then
returning the value). (Ilia)
- Fixed bug #29577 (MYSQLI_CLIENT_FOUND_ROWS undefined) (Georg)
- Fixed bug #29573 (Segmentation fault, when exception thrown within
PHP function called from XSLT). (Christian)
- Fixed bug #29522 (accessing properties without connection) (Georg)
- Fixed bug #29505 (get_class_vars() severely broken when used with arrays).
(Marcus)
- Fixed bug #29490 (.Net object instantiation failed). (Michael Sisolak).
- Fixed bug #29474 (win32: usleep() doesn't work). (Wez)
- Fixed bug #29449 (win32: feof() hangs on empty tcp stream). (Wez)
- Fixed bug #29437 (Possible crash inside array_walk_recursive()). (Ilia)
- Fixed bug #29431 (crash when parsing invalid address; invalid address
returned by stream_socket_recvfrom(), stream_socket_getname()). (Wez)
- Fixed bug #29409 (Segfault in PHP functions called from XSLT). (Rob)
- Fixed unloading of dynamically loaded extensions.
(Marcus, kameshj at fastmail dot fm)
- Fixed bug #29395 (sqlite_escape_string() returns bogus data on empty
strings). (Ilia, Tony)
- Fixed bug #29392 (com_dotnet crashes when echo'ing an object). (Wez)
- Fixed bug #29368 (The destructor is called when an exception is thrown from
the constructor). (Marcus)
- Fixed bug #29354 (Exception constructor marked as both public and protected).
(Marcus)
- Fixed bug #29342 (strtotime() does not handle empty date string properly).
(Ilia)
- Fixed bug #29340 (win32 build produces invalid php_ifx.dll). (Edin)
- Fixed bug #29335 (fetch functions now use MYSQLI_BOTH as default) (Georg)
- Fixed bug #29291 (get_class_vars() return names with NULLs). (Marcus)
- Fixed bug #29264 (gettext extension not working). (Edin)
- Fixed bug #29258 (variant_date_from_timestamp() does not honour
timezone). (Wez)
- Fixed bug #29256 (error when sending large packets on a socket). (Dmitry)
- Fixed bug #29236 (memory error when wsdl-cache is enabled). (Dmitry)
- Fixed bug #29147 (Compile Error in mnoGoSearch functions). (Sergey, Antony)
- Fixed bug #29132 ($_SERVER["PHP_AUTH_USER"] isn't defined). (Stefan)
- Fixed bug #29119 (html_entity_decode() misbehaves with UTF-8). (Moriyoshi)
- Fixed bug #29109 (SoapFault exception: [WSDL] Out of memory). (Dmitry)
- Fixed bug #29061 (soap extension segfaults). (Dmitry)
- Fixed bug #28985 (__getTypes() returning nothing on complex WSDL). (Dmitry)
- Fixed bug #28969 (Wrong data encoding of special characters). (Dmitry)
- Fixed bug #28895 (ReflectionClass::isAbstract always returns false). (Marcus)
- Fixed bug #28829 (Thread-unsafety in bcmath elementary values). (Sara)
- Fixed bug #28464 (catch() does not catch exceptions by interfaces). (Marcus)
- Fixed bug #27669 (PHP 5 didn't support all possibilities for calling static
methods dynamically). (Dmitry)
- Fixed ReflectionClass::getMethod() and ReflectionClass::getProperty() to
raise an ReflectionException instead of returning NULL on failure.
(Sebastian)
- Fixed convert.* filters to consume remaining buckets_in on flush. (Sara)
- Fixed bug in mysqli->client_version. (Georg)
13 Jul 2004, PHP 5.0.0
- Updated PCRE to provide better error handling in certain cases. (Andrei)
- Changed doc comments to require a single white space after '/**'. (Marcus)
- Fixed bug #29019 (Database not closing). (Marcus)
- Fixed bug #29008 (array_combine() does not handle non-numeric/string keys).
(Ilia)
- Fixed bug #28999 (fixed behaviour of exec() to work as it did in 4.X). (Ilia)
- Fixed bug #28868 (Internal filter registry not thread safe). (Sara)
- Fixed bug #28851 (call_user_func_array has typo in error message). (Marcus)
- Fixed bug #28831 (ArrayObject::offsetGet() does the work of offsetUnset()).
(Marcus)
- Fixed bug #28822 (ArrayObject::offsetExists() works inverted). (Marcus)
- Fixed bug #28789 (ReflectionProperty getValue() fails on public static
members). (Marcus)
- Fixed bug #28771 (Segfault when using xslt and clone). (Rob)
- Fixed bug #28751 (SoapServer does not call _autoload()). (Dmitry)
- Fixed bug #28739 (array_*diff() and array_*intersect() not clearing the fci
cache before work). (Andrey)
- Fixed bug #28721 (appendChild() and insertBefore() unset DOMText).(Rob)
- Fixed bug #28702 (SOAP does not parse WSDL service address correctly). (Dmitry)
- Fixed bug #28699 (Reflection api bugs). (Marcus)
- Fixed bug #28694 (ReflectionExtension::getFunctions() crashes PHP). (Marcus)
- Fixed bug #28512 (Allocate enough space to store MSSQL data). (Frank)
- Fixed strip_tags() to correctly handle '\0' characters. (Stefan)
7 Jun 2004, PHP 5 Release Candidate 3
- Moved the PDFLib extension to PECL. (Wez)
- Added MySQL 4.1.2-alpha and 4.1.3-beta support to MySQLI extension. (Georg)
- Added support for dumping private/protected properties to var_dump().
(Andrey)
- Added count() support for COM arrays. (Wez)
- Added Firebird/InterBase UDF source that allows PHP functions to be called
from SQL (Ard)
- Removed Firebird/Interbase function ibase_timefmt() (Ard)
- Changed user error handler mechanism to relay to built-in error handler if it
returns false. (Andrei)
- Changed class type hints for function parameters to not allow the passing of
NULL values. (Andi)
- Changed tidy_node to tidyNode and removed tidy_exception. (John)
- Fixed ip2long() to return FALSE if an IP address passed to this function
is not valid. (Derick)
- Fixed memory leak in memory manager. (Andi)
- Fixed problem with exceptions returning from include(). (Dmitry)
- Fixed bug #28641 (Instance of Interface). (Marcus)
- Fixed bug #28430 (Extending mysqli class). (Georg)
- Fixed bug #28311 (Transparency detection code is off by 1).
(Ilia, pikeman at pikeman dot sytes dot net)
- Fixed bug #28304 (Missing bounds check inside imagefilter()). (Ilia)
@@ -17,8 +261,10 @@ PHP NEWS
- Fixed bug #28287 (stream_*_register() not calling __autoload()). (Sara)
- Fixed bug #28267 (php_image_filter_contrast calls gdImageBrightness). (Ilia)
- Fixed bug #28239 (No results returned on SOAP call, no error given). (Dmitry)
- Fixed bug #28205 (num_rows property for statement object). (Georg)
- Fixed bug #28161 (COM: Array style properties could not be accessed). (Wez)
- Fixed bug #28125 (ArrayObject leaks when accessing elements). (Marcus)
- Fixed bug #28100 (NULL parameter support for mysqli_ssl_set). (Georg)
- Fixed bug #28099 (ArrayObject doesn't implement ArrayAccess). (Marcus)
- Fixed bug #27929 (SPL: change visibility of ArrayIterator::__construct).
(Marcus)
@@ -70,7 +316,6 @@ PHP NEWS
- Fixed bug #27619 (filters not applied to pre-buffered stream data). (Sara)
- Fixed bug #27519 (Reflection_Function constructor crashes with non-existant
function's name). (Marcus)
- Fixed bug #27469 (serialize() objects of incomplete class). (Dmitry)
- Fixed bug #27457 (handling of numeric indexes in strtr()). (Dmitry)
- Fixed bug #27397 (debug_backtrace() not showing function arguments). (Zeev)
- Fixed bug #27283 (The last catch statement was sometimes skipped). (Andi)
+10 -18
View File
@@ -37,8 +37,11 @@ The next few rules are more of a technical nature.
messages every day. Woe be to those who attempt to mess with it.
2. All news updates intended for public viewing, such as new features,
bug fixes, improvements, etc., should go into the NEWS file. Also see
the note below about automatically updating NEWS in your commit message.
bug fixes, improvements, etc., should go into the NEWS file.
NB! Lines, starting with @ will go automagically into NEWS file, but
this is NOT recommended, though. Please, add news entries directly to
NEWS file and don't forget to keep them adjusted and sorted.
3. Do not commit multiple file and dump all messages in one commit. If you
modified several unrelated files, commit each group separately and
@@ -59,14 +62,10 @@ The next few rules are more of a technical nature.
The format of the commit messages is pretty simple.
If a line begins with #, it is taken to be a comment and will not appear
in the ChangeLog. If the line begins with @, it will be redirected to the
NEWS file. Everything else goes into the ChangeLog.
in the ChangeLog. Everything else goes into the ChangeLog.
It is important to note that if your comment or news logline spans multiple
lines, you have to put # or @ at the beginning of _every_ such line. Every
entry in NEWS has to have a name after it, so if you did it with someone's
help, put both your names there. Your name WILL NOT be automatically put
at the end of the NEWS entry - so, please provide it yourself.
lines, you have to put # at the beginning of _every_ such line.
Example. Say you modified two files, datetime.c and string.c. In datetime.c
you added a new format option for date() function, and in string.c you fixed
@@ -78,17 +77,12 @@ For datetime.c:
(PHP date) Added new 'K' format modifier for printing out number of
days until New Year's Eve.
@- Added new 'K' format modifier that will output the number of days
@ until New Year's Eve. (Bob)
For string.c:
(php_trim) Fixed a memory leak resulting from improper use of zval_dtor().
# Man, that thing was leaking all over the place!
@- Fixed memory leak in trim(). (Bob)
The lines above marked with @ will go into NEWS file automagically, and the
# lines will be omitted from the ChangeLog. Alternatively, you might want
to modify NEWS file directly and not use the @ lines.
The # lines will be omitted from the ChangeLog automagically.
If you fix some bugs, you should note the bug ID numbers in your
commit message. Bug ID should be prefixed by "#" for easier access to
@@ -97,12 +91,10 @@ bug report when developers are browsing CVS via. LXR or Bonsai.
Example:
Fixed pgsql notice handler double free crash bug. Bug #14016
@ Fixed pgsql notice handler double free crash bug. Bug #14016
If you don't see your messages in ChangeLog and NEWS right away, don't worry!
If you don't see your messages in ChangeLog right away, don't worry!
These files are updated once a day, so your stuff will not show up until
somewhat later. Don't go adding stuff to NEWS by hand if you already put @
lines in the commit message.
somewhat later.
You can use LXR (http://lxr.php.net/) and Bonsai (http://bonsai.php.net/)
to look at PHP CVS repository in various ways.
+53 -5
View File
@@ -77,20 +77,24 @@
9. get_class() starting PHP 5 returns the name of the class as it was
declared which may lead to problems in older scripts that rely on
the previous behaviour - the class name is lowercased.
the previous behaviour - the class name is lowercased. Expect the
same behaviour from get_parent_class() when applicable.
Example :
<?php
class FooBar {
}
class ExtFooBar extends FooBar{}
$a = new FooBar();
var_dump(get_class($a));
var_dump(get_class($a), get_parent_class($a));
?>
Output (PHP 4):
string(6) "foobar"
string(9) "extfoobar"
Output (PHP 5):
string(6) "FooBar"
string(9) "ExtFooBar"
----------------------------------------------------------------------
Example code that will break :
//....
@@ -101,7 +105,51 @@
//...
}
//...
Possible solution is to search for get_class() in all your scripts and
use strtolower().
Possible solution is to search for get_class() and get_parent_class() in
all your scripts and use strtolower().
10. get_class_methods() returns the names of the methods of a class as they
declared. In PHP4 the names are all lowercased.
Example code :
<?php
class Foo{
function doFoo(){}
function hasFoo(){}
}
var_dump(get_class_methods("Foo"));
?>
Output (PHP4):
array(2) {
[0]=>
string(5) "dofoo"
[1]=>
string(6) "hasfoo"
}
Output (PHP5):
array(2) {
[0]=>
string(5) "doFoo"
[1]=>
string(6) "hasFoo"
}
11. Assignment $this is impossible. Starting PHP 5.0.0 $this has special
meaning in class methods and is recognized by the PHP parser. The latter
will generate a parse error when assignment to $this is found
Example code :
<?php
class Foo {
function assignNew($obj) {
$this = $obj;
}
}
$a = new Foo();
$b = new Foo();
$a->assignNew($b);
echo "I was executed\n";
?>
Output (PHP 4):
I was executed
Output (PHP 5):
PHP Fatal error: Cannot re-assign $this in /tmp/this_ex.php on line 4
+1 -1
View File
@@ -155,7 +155,7 @@ PHP_FUNCTION(my_get_raw)
HashTable *hash_ptr;
char *raw_var;
if(zend_parse_parameters(2 TSRMLS_CC, "ls|l", &arg, &var, &var_len) == FAILURE) {
if(zend_parse_parameters(2 TSRMLS_CC, "ls", &arg, &var, &var_len) == FAILURE) {
return;
}
-4
View File
@@ -7,13 +7,9 @@ Zend
dimensional arrays.
* Look at replacing c-lib call tolower().
* Make hash API functions work with HASH_OF() to save time.
* Allow to set a default value for call-by-reference-parameters.
eg: function hello (&$pallo = NULL) {}
* Add configure test to determine if dlsym() requires underscore and set
DLSYM_NEEDS_UNDERSCORE accordingly. Perl and zsh have it in configure,
for example. (DONE?)
* Allow foreach ($array as $k => &$val) syntax. right now we cannot
traverse an array without copying each element.
* Native large number support (probably with GNU GMP)
* Const'ify APIs. Right now, many functions leave parameters untouched,
but don't declare those as const. This makes interaction with other
+17
View File
@@ -0,0 +1,17 @@
Zend Engine
-----------
- Look at making zend_constant value member be a zval* instead of zval. (Andi)
- Add the patch for referring to existing .ini vars in .ini files. (Andrei)
- Implement inheritance rules for type hints. (Marcus)
- Implement true/false/NULL as keywords (apply the patch). (Andi, Marcus)
- Implement typehinting for arrays (apply the patch). (Andi, Marcus)
- Find a keyword for the if-set-or operator (apply the patch). (Marcus, all)
- Fix ZTS destruction (apply the patch). (Marcus)
Build System
------------
- Implement load order of built-in extensions (apply the patch). (Wez)
Standard Library
----------------
- Implement new time/date parsing and handling functions. (Derick)
-102
View File
@@ -16,83 +16,6 @@ Responsibility: Andi, Stig?
Time frame: ?
Component: Introspection
get_function_definition(<is_callable> [field]) =>
array(
file => filename
line_start =>
line_end =>
parameters => array( name, byref, default )
static_variables => array( name, value/default )
scope => 'namespace' | 'class' | null
namespace => classname | namespacename | 'main'
protection => protection_flags
phpdoc => pre-scanned-phpdoc-string
type => 'internal' | 'user'
)
get_class_definition(<class> [field]) =>
array(
type => 'internal' | 'user'
file => filename
line_start =>
line_end =>
name => pretty-name
parent => classname | namespace | null
flags => bitfield (ABSTRACT)
methods => array( array( name, phpdoc ) )
default_properties => array( array( name, value, phpdoc ) )
private_properties => array( array( name, value, phpdoc ) )
protected_properties => array( array( name, value, phpdoc ) )
public_properties => array( array( name, value, phpdoc ) )
static_members => array( array( name, value, phpdoc ) )
constants => array( array( name, value, phpdoc ) )
classes => array( array( name, phpdoc ) )
phpdoc => pre-scanned-phpdoc-string
)
get_constant_definition(<constant> [field]) =>
array(
file => filename
line_start =>
line_end =>
name =>
value =>
phpdoc =>
)
get_global_variable_defintion(<name> [field]) =>
array(
file =>
line_start =>
line_end =>
name =>
phpdoc =>
)
We tried to take into account the implementation of each piece of
information, and there are some that are problematic, especially those
regarding constants and global variables (where do we store the extra
information?)
With "pre-scanned-phpdoc-string" we mean converting:
/**
* Blah blah blah
* @param foo ...
*/
to:
Blah blah blah
@param foo
The rest of the phpdoc handling should be left to an extension.
Responsibility: Stig, Andrei, Harald
Time frame: ?
Component: Redesign of API Versioning
Responsibility: ?
Time frame: 1 month
@@ -172,31 +95,6 @@ Responsibility: Sterling, Harald
Time frame: ?
Component: MySQL Extension
Complete rewrite, leveraging the new MySQL 4 / MySQL 5
features.
Responsibility: Georg Richter, Zak Greant
Timeframe: ?
Component: XML
- Rewrite DOMXML and incorporate all (or most of) W3C-DOM2.
- Use the new ZE2 features (Exceptions, setter/getter).
- Add SAX(2), XML Schema.
- XSLT, HTML, XPath, XPointer, DTD Validation will still be
supported, have to find a meaningful API for it.
- Break BC, warn users now.
- Look at the libxml2 patch by lukas schröder and see if we can prevent
memory leaks with it (anyway, getting rid of mem-leaks and intelligent
memory management is on top prio...)
- In the longer term, domxml (or another name, as with todays features
domxml is a little bit misleading) shall be the main xml-class, which
covers most of what's needed for decent XML support in PHP ;)
But there is certainly place for others like Sablotron etc.
Responsibility: Christian Stocker
Timeframe: ?
Component: Test Suite
Extending the test suite with atleast a test for every
function in an extension that doesn't require external
+51 -10
View File
@@ -308,15 +308,22 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
if (path_length == 0)
return (0);
if (path_length >= MAXPATHLEN)
return (1);
#if !defined(TSRM_WIN32) && !defined(NETWARE)
/* cwd_length can be 0 when getcwd() fails.
* This can happen under solaris when a dir does not have read permissions
* but *does* have execute permissions */
if (IS_ABSOLUTE_PATH(path, path_length) || (state->cwd_length < 1)) {
if (use_realpath && realpath(path, resolved_path)) {
path = resolved_path;
path_length = strlen(path);
if (use_realpath) {
if (realpath(path, resolved_path)) {
path = resolved_path;
path_length = strlen(path);
} else {
/* disable for now
return 1; */
}
}
} else { /* Concat current directory with relative path and then run realpath() on it */
char *tmp;
@@ -332,9 +339,19 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
memcpy(ptr, path, path_length);
ptr += path_length;
*ptr = '\0';
if (use_realpath && realpath(tmp, resolved_path)) {
path = resolved_path;
path_length = strlen(path);
if (strlen(tmp) >= MAXPATHLEN) {
free(tmp);
return 1;
}
if (use_realpath) {
if (realpath(tmp, resolved_path)) {
path = resolved_path;
path_length = strlen(path);
} else {
/* disable for now
free(tmp);
return 1; */
}
}
free(tmp);
}
@@ -851,13 +868,24 @@ CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
{
int command_length;
int dir_length, extra = 0;
char *command_line;
char *ptr;
char *ptr, *dir;
FILE *retval;
command_length = strlen(command);
ptr = command_line = (char *) malloc(command_length + sizeof("cd ; ") + CWDG(cwd).cwd_length+1);
dir_length = CWDG(cwd).cwd_length;
dir = CWDG(cwd).cwd;
while (dir_length > 0) {
if (*dir == '\'') extra+=3;
dir++;
dir_length--;
}
dir_length = CWDG(cwd).cwd_length;
dir = CWDG(cwd).cwd;
ptr = command_line = (char *) malloc(command_length + sizeof("cd '' ; ") + dir_length +1+1);
if (!command_line) {
return NULL;
}
@@ -867,8 +895,21 @@ CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
if (CWDG(cwd).cwd_length == 0) {
*ptr++ = DEFAULT_SLASH;
} else {
memcpy(ptr, CWDG(cwd).cwd, CWDG(cwd).cwd_length);
ptr += CWDG(cwd).cwd_length;
*ptr++ = '\'';
while (dir_length > 0) {
switch (*dir) {
case '\'':
*ptr++ = '\'';
*ptr++ = '\\';
*ptr++ = '\'';
/* fall-through */
default:
*ptr++ = *dir;
}
dir++;
dir_length--;
}
*ptr++ = '\'';
}
*ptr++ = ' ';
+233
View File
@@ -1,3 +1,236 @@
2004-07-14 Stanislav Malyshev <stas@zend.com>
* zend_object_handlers.c:
be consistent with write_dimension
* zend_object_handlers.c:
fix #28957
2004-07-13 Andi Gutmans <andi@zend.com>
* zend.h:
- 5.0.1-dev
2004-07-13 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_constants.c:
Bugfix #29116 Zend constant warning uses memory after free (jdolecek at
NetBSD dot org)
2004-07-13 Andi Gutmans <andi@zend.com>
* (php_5_0_0)
zend.h:
- Roll PHP 5.0.0
2004-07-12 Ilia Alshanetsky <ilia@prohost.org>
* (php_5_0_0RC4)
zend_execute.c:
Fixed bug #29086 & #28064 (PHP crashes on extremly long scripts).
2004-07-12 Andi Gutmans <andi@zend.com>
* (php_5_0_0RC4)
zend.c:
- Convert zend_class_entry -> zend_class_entry *
2004-07-10 Jon Parise <jon+php@csh.rit.edu>
* zend.c:
DragonFly BSD is derived from FreeBSD and requires the same floating point
precision fix.
2004-07-10 Andi Gutmans <andi@zend.com>
* zend_alloc.c
zend_hash.c
zend_variables.c:
- Better stability during premature shutdown of request startup
2004-07-05 Andi Gutmans <andi@zend.com>
* zend_mm.h:
- Disable zend_mm for 5.0.0
2004-07-03 Andi Gutmans <andi@zend.com>
* zend_alloc.c:
- Should fix mem leak with ZEND_MM. I made this change a while ago and
- rolled it back but I don't remember why. Please test!
2004-07-01 Ilia Alshanetsky <ilia@prohost.org>
* zend_constants.c:
Do not use alloca() where it can be easily abused by the users.
2004-06-25 Wez Furlong <wez.php@thebrainroom.net>
* zend_stream.c
zend_stream.h:
export zend stream functions for zend extensions under windows
2004-06-24 Sara Golemon <php@alphaweb.net>
* zend_execute.c:
Ease off on severity of new error (Using Resources as array offsets)
2004-06-23 Sara Golemon <php@alphaweb.net>
* zend_execute.c:
BugFix #28879 Inconsistent behavior between explicit and implicit array
creation.
Changes:
Throw E_WARNING "Illegal offset type" when explicitly creating
array elements with objects, arrays, or resorces as indexes.
This matches implicit creation w/ obj/arr indices.
Throw E_WARNING "Resource ID#%ld used as offset, casting to integer (%ld)"
when implicitly creating array with resource as index. (BC)
2004-06-19 Sebastian Bergmann <sb@sebastian-bergmann.de>
* zend_reflection_api.c:
Reflection_* -> Reflection*. Patch by Timm Friebe.
2004-06-18 Sara Golemon <php@alphaweb.net>
* zend_execute.c:
Another typo in converting array index doubles to long.
2004-06-18 George Schlossnagle <george@omniti.com>
* zend_builtin_functions.c:
fix for 28213.
class_name and call_type should be reinitialized on every loop iter.
2004-06-17 Sara Golemon <php@alphaweb.net>
* zend_builtin_functions.c:
String length in parse_parameters should be int
2004-06-15 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_reflection_api.c:
2004-06-14 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_language_scanner.l:
Need {} here
2004-06-10 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_language_scanner.l:
- Require a single white-space char after /** to start a doc comment that
way we prevent /*** from becoming a doc comment (as requested Derick).
* zend_API.h:
Add missing declaration
* zend_reflection_api.c:
Small code layout change
* zend_language_scanner.l:
Do not require NEWLINE at start of doccomment
* zend_reflection_api.c:
Bugfix #28699: Reflection api bugs
2004-06-09 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_reflection_api.c:
Fix Bug #28694 ReflectionExtension::getFunctions() crashes PHP
2004-06-07 Andi Gutmans <andi@zend.com>
* zend.h:
- Go back to -dev (Shouldn't need another RC)
* (php_5_0_0RC3)
zend.h:
- Roll RC3
2004-06-06 Stefan Esser <sesser@suspekt.org>
* zend_compile.h
zend_opcode.c:
Fixed Zend Function Destructor to use correct TSRM handle.
2004-06-05 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_API.c:
Fix #28641: Instance of Interface
2004-06-03 Andi Gutmans <andi@zend.com>
* (php_5_0_0RC3RC2)
zend.h:
- Prepare for RC3RC2
2004-06-02 Andi Gutmans <andi@zend.com>
* zend_mm.h:
- Don't use ZEND_MM in Windows
2004-06-02 Stanislav Malyshev <stas@zend.com>
* zend_execute.c:
fix incdec - make value's refcount non-zero when passing to
write_property - otherwise __set caller cleanup could kill it.
2004-06-01 Andi Gutmans <andi@zend.com>
* zend.c:
- If user error handler returns "false" then we relay to the built in error
handler
2004-05-31 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_reflection_api.c:
Refcount must not be set separatley again.
* zend_reflection_api.c
zend_reflection_api.c:
Add missing initialization
* zend_compile.c:
2004-05-28 Andrei Zmievski <andreiz@gmail.com>
* zend.c:
Allow user-defined error handlers to indicate whether default error
handler should be re-invoked, by returning true or false.
2004-05-28 Marcus Boerger <marcus.boerger@post.rwth-aachen.de>
* zend_execute.c:
Prevent possible problems with illegal properties
2004-05-28 Derick Rethans <php@derickrethans.nl>
* zend_builtin_functions.c:
- Make the default mask for user defined error handlers include ALL errors,
including E_STRICT.
2004-05-27 Andi Gutmans <andi@zend.com>
* zend.h:
- Back to RC3-dev until we roll final
* (php_5_0_0RC3RC1)
zend_execute.c:
- Fix problem with exceptions returning from include(). (Dmitry)
* (php_5_0_0RC3RC1)
zend.h:
- RC3RC1
2004-05-26 Wez Furlong <wez.php@thebrainroom.net>
* zend_object_handlers.c:
+2 -1
View File
@@ -16,7 +16,8 @@ libZend_la_SOURCES=\
zend_ini.c zend_qsort.c zend_objects.c zend_object_handlers.c \
zend_objects_API.c zend_ts_hash.c zend_stream.c zend_mm.c \
zend_default_classes.c zend_reflection_api.c \
zend_iterators.c zend_interfaces.c zend_exceptions.c
zend_iterators.c zend_interfaces.c zend_exceptions.c \
zend_strtod.c
libZend_la_LDFLAGS =
libZend_la_LIBADD = @ZEND_EXTRA_LIBS@
+42 -1
View File
@@ -545,7 +545,7 @@ Changes in the Zend Engine 2.0
<?php
class Exception {
function __construct(string $message=NULL, int $code=0) {
function __construct(/*string*/ $message=NULL, /*int*/ $code=0) {
if (func_num_args()) {
$this->message = $message;
}
@@ -890,6 +890,47 @@ Changes in the Zend Engine 2.0
the use of all abstract methods declared in the interfaces Iterator
and IteratorAggregate respectively.
* Array overloading
Objects can be used with Array notation when they implement the
interface ArrayAccess. You cannot use such objects in standard
array functions, however you have full control over the array
notation. This allows lazy initialization or read only array.
Note that setting [] results in a call to offsetSet() with
index being NULL. That means that as with standard arrays you
cannot store NULL keys.
Example:
<?php
class ArrayClass implements ArrayAccess {
public $a = array();
function offsetExists($index) {
return array_key_exists($index, $this->a);
}
function offsetGet($index) {
return $this->a[$index];
}
function offsetSet($index, $newval) {
return $this->a[$index] = $newval;
}
function offsetUnset($index) {
unset($this->a[$index]);
}
}
$obj = new ArrayClass;
$obj[0] = 'bla'; // calls offsetSet(0,'bla')
$obj[] = 42; // calls offsetSet(NULL, 42)
$x = $obj[0]; // calls offsetGet(0)
$b = isset($obj[0]); // calls offsetExists(0)
unset($obj[0]); // calls offsetUnset(0)
?>
* __METHOD__
The pseudo constant __METHOD__ shows the current class and method
+27 -19
View File
@@ -7,20 +7,20 @@
CFG=Zend - Win32 Release_inline
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE
!MESSAGE NMAKE /f "Zend.mak".
!MESSAGE
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE
!MESSAGE NMAKE /f "Zend.mak" CFG="Zend - Win32 Release_inline"
!MESSAGE
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE
!MESSAGE "Zend - Win32 Release" (based on "Win32 (x86) Static Library")
!MESSAGE "Zend - Win32 Debug" (based on "Win32 (x86) Static Library")
!MESSAGE "Zend - Win32 Release_inline" (based on "Win32 (x86) Static Library")
!MESSAGE
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -95,7 +95,7 @@ LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
# ADD LIB32 /nologo
!ENDIF
!ENDIF
# Begin Target
@@ -135,10 +135,6 @@ SOURCE=.\zend_default_classes.c
# End Source File
# Begin Source File
SOURCE=.\zend_interfaces.c
# End Source File
# Begin Source File
SOURCE=.\zend_dynamic_array.c
# End Source File
# Begin Source File
@@ -179,6 +175,10 @@ SOURCE=.\zend_ini_scanner.c
# End Source File
# Begin Source File
SOURCE=.\zend_interfaces.c
# End Source File
# Begin Source File
SOURCE=".\zend_language_parser.c"
# End Source File
# Begin Source File
@@ -243,6 +243,10 @@ SOURCE=.\zend_stream.c
# End Source File
# Begin Source File
SOURCE=.\zend_strtod.c
# End Source File
# Begin Source File
SOURCE=.\zend_ts_hash.c
# End Source File
# Begin Source File
@@ -291,10 +295,6 @@ SOURCE=.\zend_default_classes.h
# End Source File
# Begin Source File
SOURCE=.\zend_interfaces.h
# End Source File
# Begin Source File
SOURCE=.\zend_dynamic_array.h
# End Source File
# Begin Source File
@@ -351,6 +351,10 @@ SOURCE=.\zend_ini_scanner.h
# End Source File
# Begin Source File
SOURCE=.\zend_interfaces.h
# End Source File
# Begin Source File
SOURCE=.\zend_istdiostream.h
# End Source File
# Begin Source File
@@ -415,6 +419,10 @@ SOURCE=.\zend_stream.h
# End Source File
# Begin Source File
SOURCE=.\zend_strtod.h
# End Source File
# Begin Source File
SOURCE=.\zend_ts_hash.h
# End Source File
# Begin Source File
@@ -449,7 +457,7 @@ BuildCmds= \
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
!ENDIF
!ENDIF
# End Source File
# Begin Source File
@@ -504,7 +512,7 @@ BuildCmds= \
$(BuildCmds)
# End Custom Build
!ENDIF
!ENDIF
# End Source File
# End Group
@@ -533,7 +541,7 @@ InputPath=.\zend_ini_scanner.l
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
!ENDIF
!ENDIF
# End Source File
# Begin Source File
@@ -570,7 +578,7 @@ InputPath=".\zend_language_scanner.l"
# End Custom Build
!ENDIF
!ENDIF
# End Source File
# End Group
+8
View File
@@ -276,6 +276,10 @@ SOURCE=.\zend_stream.c
# End Source File
# Begin Source File
SOURCE=.\zend_strtod.c
# End Source File
# Begin Source File
SOURCE=.\zend_ts_hash.c
# End Source File
# Begin Source File
@@ -452,6 +456,10 @@ SOURCE=.\zend_stream.h
# End Source File
# Begin Source File
SOURCE=.\zend_strtod.h
# End Source File
# Begin Source File
SOURCE=.\zend_ts_hash.h
# End Source File
# Begin Source File
+72
View File
@@ -0,0 +1,72 @@
--TEST--
Bug #27798 (private / protected variables not exposed by get_object_vars() inside class)
--FILE--
<?php
class Base
{
public $Foo = 1;
protected $Bar = 2;
private $Baz = 3;
function __construct()
{
echo __METHOD__ . "\n";
var_dump(get_object_vars($this));
}
}
class Child extends Base
{
private $Baz = 4;
function __construct()
{
parent::__construct();
echo __METHOD__ . "\n";
var_dump(get_object_vars($this));
}
}
var_dump(get_object_vars(new Base));
var_dump(get_object_vars(new Child));
?>
===DONE===
--EXPECT--
Base::__construct
array(3) {
["Foo"]=>
int(1)
["Bar"]=>
int(2)
["Baz"]=>
int(3)
}
array(1) {
["Foo"]=>
int(1)
}
Base::__construct
array(3) {
["Baz"]=>
int(4)
["Foo"]=>
int(1)
["Bar"]=>
int(2)
}
Child::__construct
array(3) {
["Baz"]=>
int(4)
["Foo"]=>
int(1)
["Bar"]=>
int(2)
}
array(1) {
["Foo"]=>
int(1)
}
===DONE===
+74
View File
@@ -0,0 +1,74 @@
--TEST--
Bug #28444 (Cannot access undefined property for object with overloaded property access)
--FILE--
<?php
class Object
{
public $x;
function __construct($x)
{
$this->x = $x;
}
}
class Overloaded
{
public $props = array();
public $x;
function __construct($x)
{
$this->x = new Object($x);
}
function __get($prop)
{
echo __METHOD__ . "($prop)\n";
return $this->props[$prop];
}
function __set($prop, $val)
{
echo __METHOD__ . "($prop,$val)\n";
$this->props[$prop] = $val;
}
}
$y = new Overloaded(2);
var_dump($y->x);
var_dump($y->x->x);
var_dump($y->x->x = 3);
var_dump($y->y = 3);
var_dump($y->y);
var_dump($y->z = new Object(4));
var_dump($y->z->x);
$t = $y->z;
var_dump($t->x = 5);
var_dump($y->z->x = 6);
?>
===DONE===
--EXPECTF--
object(Object)#%d (1) {
["x"]=>
int(2)
}
int(2)
int(3)
Overloaded::__set(y,3)
int(3)
Overloaded::__get(y)
int(3)
Overloaded::__set(z,Object id #3)
object(Object)#%d (1) {
["x"]=>
int(4)
}
Overloaded::__get(z)
int(4)
Overloaded::__get(z)
int(5)
Overloaded::__get(z)
int(6)
===DONE===
+34
View File
@@ -0,0 +1,34 @@
--TEST--
Bug #29368 (The destructor is called when an exception is thrown from the constructor)
--FILE--
<?
class Foo
{
function __construct()
{
echo __METHOD__ . "\n";
throw new Exception;
}
function __destruct()
{
echo __METHOD__ . "\n";
}
}
try
{
$bar = new Foo;
} catch(Exception $exc)
{
echo "Caught exception!\n";
}
unset($bar);
?>
===DONE===
--EXPECTF--
Foo::__construct
Caught exception!
===DONE===
+31
View File
@@ -0,0 +1,31 @@
--TEST--
Bug #29505 (get_class_vars() severely broken when used with arrays)
--FILE--
<?php
class Test {
public $empty = array();
public $three = array(1, "b"=>"c", 3=>array());
}
var_dump(get_class_vars('Test'));
?>
===DONE===
--EXPECT--
array(2) {
["empty"]=>
array(0) {
}
["three"]=>
array(3) {
[0]=>
int(1)
["b"]=>
string(1) "c"
[3]=>
array(0) {
}
}
}
===DONE===
+13
View File
@@ -0,0 +1,13 @@
--TEST--
Bug #29883 (isset gives invalid values on strings)
--FILE--
<?php
$x = "bug";
var_dump(isset($x[-1]));
var_dump(isset($x["1"]));
echo $x["1"]."\n";
?>
--EXPECT--
bool(false)
bool(true)
u
+13
View File
@@ -0,0 +1,13 @@
--TEST--
Bug #30922 (reflective functions crash PHP when interfaces extend themselves)
--FILE--
<?php
interface RecurisiveFooFar extends RecurisiveFooFar {}
class A implements RecurisiveFooFar {}
$a = new A();
var_dump($a instanceOf A);
echo "ok\n";
?>
--EXPECTF--
Fatal error: Interface RecurisiveFooFar cannot not implement itself in %sbug30922.php on line %d
+19 -8
View File
@@ -83,7 +83,6 @@ ZEND_INI_END()
ZEND_API int compiler_globals_id;
ZEND_API int executor_globals_id;
ZEND_API int alloc_globals_id;
zend_class_entry global_main_class;
HashTable *global_function_table;
HashTable *global_class_table;
HashTable *global_constants_table;
@@ -429,7 +428,7 @@ static void zend_set_default_compile_time_values(TSRMLS_D)
static void compiler_globals_ctor(zend_compiler_globals *compiler_globals TSRMLS_DC)
{
zend_function tmp_func;
zend_class_entry tmp_class;
zend_class_entry *tmp_class;
compiler_globals->compiled_filename = NULL;
@@ -439,7 +438,7 @@ static void compiler_globals_ctor(zend_compiler_globals *compiler_globals TSRMLS
compiler_globals->class_table = (HashTable *) malloc(sizeof(HashTable));
zend_hash_init_ex(compiler_globals->class_table, 10, NULL, ZEND_CLASS_DTOR, 1, 0);
zend_hash_copy(compiler_globals->class_table, global_class_table, (copy_ctor_func_t) zend_class_add_ref, &tmp_class, sizeof(zend_class_entry));
zend_hash_copy(compiler_globals->class_table, global_class_table, (copy_ctor_func_t) zend_class_add_ref, &tmp_class, sizeof(zend_class_entry *));
zend_set_default_compile_time_values(TSRMLS_C);
@@ -512,8 +511,8 @@ static void alloc_globals_dtor(zend_alloc_globals *alloc_globals_p TSRMLS_DC)
#endif
#ifdef __FreeBSD__
/* FreeBSD floating point precision fix */
#if defined(__FreeBSD__) || defined(__DragonFly__)
/* FreeBSD and DragonFly floating point precision fix */
#include <floatingpoint.h>
#endif
@@ -554,8 +553,8 @@ int zend_startup(zend_utility_functions *utility_functions, char **extensions, i
alloc_globals_ctor(&alloc_globals TSRMLS_CC);
#endif
#ifdef __FreeBSD__
/* FreeBSD floating point precision fix */
#if defined(__FreeBSD__) || defined(__DragonFly__)
/* FreeBSD and DragonFly floating point precision fix */
fpsetmask(0);
#endif
@@ -866,6 +865,7 @@ ZEND_API int zend_get_configuration_directive(char *name, uint name_length, zval
ZEND_API void zend_error(int type, const char *format, ...)
{
va_list args;
va_list usr_copy;
zval ***params;
zval *retval;
zval *z_error_type, *z_error_message, *z_error_filename, *z_error_lineno, *z_context;
@@ -937,7 +937,15 @@ ZEND_API void zend_error(int type, const char *format, ...)
ALLOC_INIT_ZVAL(z_error_lineno);
ALLOC_INIT_ZVAL(z_context);
z_error_message->value.str.len = zend_vspprintf(&z_error_message->value.str.val, 0, format, args);
#if defined(va_copy)
va_copy(usr_copy, args);
#else
usr_copy = args;
#endif
z_error_message->value.str.len = zend_vspprintf(&z_error_message->value.str.val, 0, format, usr_copy);
#if defined(va_copy)
va_end(usr_copy);
#endif
z_error_message->type = IS_STRING;
z_error_type->value.lval = type;
@@ -974,6 +982,9 @@ ZEND_API void zend_error(int type, const char *format, ...)
if (call_user_function_ex(CG(function_table), NULL, orig_user_error_handler, &retval, 5, params, 1, NULL TSRMLS_CC)==SUCCESS) {
if (retval) {
if (Z_TYPE_P(retval) == IS_BOOL && Z_LVAL_P(retval) == 0) {
zend_error_cb(type, error_filename, error_lineno, format, args);
}
zval_ptr_dtor(&retval);
}
} else {
+2 -2
View File
@@ -22,7 +22,7 @@
#ifndef ZEND_H
#define ZEND_H
#define ZEND_VERSION "2.0.0RC3RC1"
#define ZEND_VERSION "2.0.3RC2"
#define ZEND_ENGINE_2
@@ -91,7 +91,7 @@ const char *zend_mh_bundle_error(void);
#endif /* HAVE_MACH_O_DYLD_H */
#if defined(HAVE_LIBDL)
#if defined(HAVE_LIBDL) && !defined(HAVE_MACH_O_DYLD_H)
# ifndef RTLD_LAZY
# define RTLD_LAZY 1 /* Solaris 1, FreeBSD's (2.1.7.1 and older) */
+87 -15
View File
@@ -316,11 +316,13 @@ static char *zend_parse_arg_impl(zval **arg, va_list *va, char **spec TSRMLS_DC)
*pl = Z_STRLEN_PP(arg);
break;
case IS_OBJECT: {
if (Z_OBJ_HANDLER_PP(arg, cast_object)
&& Z_OBJ_HANDLER_PP(arg, cast_object)(*arg, *arg, IS_STRING, 0 TSRMLS_CC) == SUCCESS) {
*pl = Z_STRLEN_PP(arg);
*p = Z_STRVAL_PP(arg);
break;
if (Z_OBJ_HANDLER_PP(arg, cast_object)) {
SEPARATE_ZVAL_IF_NOT_REF(arg);
if (Z_OBJ_HANDLER_PP(arg, cast_object)(*arg, *arg, IS_STRING, 0 TSRMLS_CC) == SUCCESS) {
*pl = Z_STRLEN_PP(arg);
*p = Z_STRVAL_PP(arg);
break;
}
}
}
@@ -694,6 +696,11 @@ ZEND_API int _object_and_properties_init(zval *arg, zend_class_entry *class_type
zval *tmp;
zend_object *object;
if (class_type->ce_flags & (ZEND_ACC_INTERFACE|ZEND_ACC_IMPLICIT_ABSTRACT_CLASS|ZEND_ACC_EXPLICIT_ABSTRACT_CLASS)) {
char *what = class_type->ce_flags & ZEND_ACC_INTERFACE ? "interface" : "abstract class";
zend_error(E_ERROR, "Cannot instantiate %s %s", what, class_type->name);
}
if (!class_type->constants_updated) {
zend_hash_apply_with_argument(&class_type->default_properties, (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
zend_hash_apply_with_argument(class_type->static_members, (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
@@ -1211,6 +1218,29 @@ ZEND_API int zend_startup_module(zend_module_entry *module)
return zend_register_module_ex(module TSRMLS_CC);
}
void zend_check_magic_method_implementation(zend_class_entry *ce, zend_function *fptr, int error_type TSRMLS_DC)
{
char lcname[16];
int name_len;
/* we don't care if the function name is longer, in fact lowercasing only
* the beginning of the name speeds up the check process */
name_len = strlen(fptr->common.function_name);
zend_str_tolower_copy(lcname, fptr->common.function_name, MIN(name_len, sizeof(lcname)-1));
lcname[sizeof(lcname)-1] = '\0'; /* zend_str_tolower_copy won't necessarily set the zero byte */
if (name_len == sizeof(ZEND_DESTRUCTOR_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_DESTRUCTOR_FUNC_NAME, sizeof(ZEND_DESTRUCTOR_FUNC_NAME)) && fptr->common.num_args != 0) {
zend_error(error_type, "Destuctor %s::%s() cannot take arguments", ce->name, ZEND_DESTRUCTOR_FUNC_NAME);
} else if (name_len == sizeof(ZEND_CLONE_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_CLONE_FUNC_NAME, sizeof(ZEND_CLONE_FUNC_NAME)) && fptr->common.num_args != 0) {
zend_error(error_type, "Method %s::%s() cannot accept any arguments", ce->name, ZEND_CLONE_FUNC_NAME);
} else if (name_len == sizeof(ZEND_GET_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_GET_FUNC_NAME, sizeof(ZEND_GET_FUNC_NAME)) && fptr->common.num_args != 1) {
zend_error(error_type, "Method %s::%s() must take exactly 1 argument", ce->name, ZEND_GET_FUNC_NAME);
} else if (name_len == sizeof(ZEND_SET_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_SET_FUNC_NAME, sizeof(ZEND_SET_FUNC_NAME)) && fptr->common.num_args != 2) {
zend_error(error_type, "Method %s::%s() must take exactly 2 arguments", ce->name, ZEND_SET_FUNC_NAME);
} else if (name_len == sizeof(ZEND_CALL_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_CALL_FUNC_NAME, sizeof(ZEND_CALL_FUNC_NAME)) && fptr->common.num_args != 2) {
zend_error(error_type, "Method %s::%s() must take exactly 2 arguments", ce->name, ZEND_CALL_FUNC_NAME);
}
}
/* registers all functions in *library_functions in the function hash */
ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entry *functions, HashTable *function_table, int type TSRMLS_DC)
@@ -1221,9 +1251,11 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
int count=0, unload=0;
HashTable *target_function_table = function_table;
int error_type;
zend_function *ctor = NULL, *dtor = NULL, *clone = NULL;
zend_function *ctor = NULL, *dtor = NULL, *clone = NULL, *__get = NULL, *__set = NULL, *__call = NULL;
char *lowercase_name;
int fname_len;
char *lc_class_name;
int class_name_len;
if (type==MODULE_PERSISTENT) {
error_type = E_CORE_WARNING;
@@ -1235,6 +1267,11 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
target_function_table = CG(function_table);
}
internal_function->type = ZEND_INTERNAL_FUNCTION;
if (scope) {
class_name_len = strlen(scope->name);
lc_class_name = zend_str_tolower_dup(scope->name, class_name_len);
}
while (ptr->fname) {
internal_function->handler = ptr->handler;
@@ -1304,18 +1341,28 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
* If it's an old-style constructor, store it only if we don't have
* a constructor already.
*/
if (!strcmp(ptr->fname, scope->name) && !ctor) {
if ((fname_len == class_name_len) && !memcmp(lowercase_name, lc_class_name, class_name_len+1) && !ctor) {
ctor = reg_function;
} else if (!strcmp(ptr->fname, ZEND_CONSTRUCTOR_FUNC_NAME)) {
} else if ((fname_len == sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_CONSTRUCTOR_FUNC_NAME, sizeof(ZEND_CONSTRUCTOR_FUNC_NAME))) {
ctor = reg_function;
} else if (!strcmp(ptr->fname, ZEND_DESTRUCTOR_FUNC_NAME)) {
} else if ((fname_len == sizeof(ZEND_DESTRUCTOR_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_DESTRUCTOR_FUNC_NAME, sizeof(ZEND_DESTRUCTOR_FUNC_NAME))) {
dtor = reg_function;
if (internal_function->num_args) {
zend_error(error_type, "Destructor %s::%s() cannot take arguments", scope->name, ptr->fname);
}
} else if (!strcmp(ptr->fname, ZEND_CLONE_FUNC_NAME)) {
} else if ((fname_len == sizeof(ZEND_CLONE_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_CLONE_FUNC_NAME, sizeof(ZEND_CLONE_FUNC_NAME))) {
clone = reg_function;
} else if ((fname_len == sizeof(ZEND_CALL_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_CALL_FUNC_NAME, sizeof(ZEND_CALL_FUNC_NAME))) {
__call = reg_function;
} else if ((fname_len == sizeof(ZEND_GET_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_GET_FUNC_NAME, sizeof(ZEND_GET_FUNC_NAME))) {
__get = reg_function;
} else if ((fname_len == sizeof(ZEND_SET_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_SET_FUNC_NAME, sizeof(ZEND_SET_FUNC_NAME))) {
__set = reg_function;
} else {
reg_function = NULL;
}
if (reg_function) {
zend_check_magic_method_implementation(scope, reg_function, error_type TSRMLS_CC);
}
}
ptr++;
@@ -1323,9 +1370,12 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
free_alloca(lowercase_name);
}
if (unload) { /* before unloading, display all remaining bad function in the module */
if (scope) {
efree(lc_class_name);
}
while (ptr->fname) {
if (zend_hash_exists(target_function_table, ptr->fname, strlen(ptr->fname)+1)) {
zend_error(error_type, "Function registration failed - duplicate name - %s", ptr->fname);
zend_error(error_type, "Function registration failed - duplicate name - %s%s%s", scope ? scope->name : "", scope ? "::" : "", ptr->fname);
}
ptr++;
}
@@ -1336,27 +1386,49 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
scope->constructor = ctor;
scope->destructor = dtor;
scope->clone = clone;
scope->__call = __call;
scope->__get = __get;
scope->__set = __set;
if (ctor) {
ctor->common.fn_flags |= ZEND_ACC_CTOR;
if (ctor->common.fn_flags & ZEND_ACC_STATIC) {
zend_error(error_type, "Constructor %s::%s cannot be static", ctor->common.scope->name, ctor->common.function_name);
zend_error(error_type, "Constructor %s::%s() cannot be static", scope->name, ctor->common.function_name);
}
ctor->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC;
}
if (dtor) {
dtor->common.fn_flags |= ZEND_ACC_DTOR;
if (dtor->common.fn_flags & ZEND_ACC_STATIC) {
zend_error(error_type, "Destructor %s::%s cannot be static", dtor->common.scope->name, dtor->common.function_name);
zend_error(error_type, "Destructor %s::%s() cannot be static", scope->name, dtor->common.function_name);
}
dtor->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC;
}
if (clone) {
clone->common.fn_flags |= ZEND_ACC_CLONE;
if (clone->common.fn_flags & ZEND_ACC_STATIC) {
zend_error(error_type, "Constructor %s::%s cannot be static", clone->common.scope->name, clone->common.function_name);
zend_error(error_type, "Constructor %s::%s() cannot be static", scope->name, clone->common.function_name);
}
clone->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC;
}
if (__call) {
if (__call->common.fn_flags & ZEND_ACC_STATIC) {
zend_error(error_type, "Method %s::%s() cannot be static", scope->name, __call->common.function_name);
}
__call->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC;
}
if (__get) {
if (__get->common.fn_flags & ZEND_ACC_STATIC) {
zend_error(error_type, "Method %s::%s() cannot be static", scope->name, __get->common.function_name);
}
__get->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC;
}
if (__set) {
if (__set->common.fn_flags & ZEND_ACC_STATIC) {
zend_error(error_type, "Method %s::%s() cannot be static", scope->name, __set->common.function_name);
}
__set->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC;
}
efree(lc_class_name);
}
return SUCCESS;
}
+2
View File
@@ -167,6 +167,8 @@ ZEND_API int zend_parse_method_parameters_ex(int flags, int num_args TSRMLS_DC,
ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entry *functions, HashTable *function_table, int type TSRMLS_DC);
ZEND_API void zend_unregister_functions(zend_function_entry *functions, int count, HashTable *function_table TSRMLS_DC);
ZEND_API int zend_register_module(zend_module_entry *module_entry);
ZEND_API int zend_register_module_ex(zend_module_entry *module TSRMLS_DC);
void zend_check_magic_method_implementation(zend_class_entry *ce, zend_function *fptr, int error_type TSRMLS_DC);
ZEND_API zend_class_entry *zend_register_internal_class(zend_class_entry *class_entry TSRMLS_DC);
ZEND_API zend_class_entry *zend_register_internal_class_ex(zend_class_entry *class_entry, zend_class_entry *parent_ce, char *parent_name TSRMLS_DC);
+7 -4
View File
@@ -75,7 +75,7 @@ static long mem_block_end_magic = MEM_BLOCK_END_MAGIC;
#define _CHECK_MEMORY_LIMIT(s, rs, file, lineno) { AG(allocated_memory) += rs;\
if (AG(memory_limit)<AG(allocated_memory)) {\
int php_mem_limit = AG(memory_limit); \
if (AG(memory_limit)+1048576 > AG(allocated_memory) - rs) { \
if (EG(in_execution) && AG(memory_limit)+1048576 > AG(allocated_memory) - rs) { \
AG(memory_limit) = AG(allocated_memory) + 1048576; \
if (file) { \
zend_error(E_ERROR,"Allowed memory size of %d bytes exhausted at %s:%d (tried to allocate %d bytes)", php_mem_limit, file, lineno, s); \
@@ -481,7 +481,7 @@ ZEND_API void shutdown_memory_manager(int silent, int full_shutdown TSRMLS_DC)
unsigned int i, j;
zend_mem_header *ptr;
for (i=1; i<MAX_CACHED_MEMORY; i++) {
for (i=0; i<MAX_CACHED_MEMORY; i++) {
for (j=0; j<AG(cache_count)[i]; j++) {
ptr = (zend_mem_header *) AG(cache)[i][j];
# if MEMORY_LIMIT
@@ -496,10 +496,12 @@ ZEND_API void shutdown_memory_manager(int silent, int full_shutdown TSRMLS_DC)
#endif /* !ZEND_DISABLE_MEMORY_CACHE */
#if defined(ZEND_MM) && !ZEND_DEBUG
zend_mm_shutdown(&AG(mm_heap));
if (full_shutdown) {
zend_mm_shutdown(&AG(mm_heap));
return;
}
zend_mm_startup(&AG(mm_heap), 256*1024);
#elif defined(ZEND_WIN32) && !ZEND_DEBUG
if (full_shutdown && AG(memory_heap)) {
HeapDestroy(AG(memory_heap));
@@ -621,10 +623,11 @@ ZEND_API void shutdown_memory_manager(int silent, int full_shutdown TSRMLS_DC)
#endif
#if defined(ZEND_MM) && ZEND_DEBUG
zend_mm_shutdown(&AG(mm_heap));
if (full_shutdown) {
zend_mm_shutdown(&AG(mm_heap));
return;
}
zend_mm_startup(&AG(mm_heap), 256*1024);
#elif defined(ZEND_WIN32) && ZEND_DEBUG
if (full_shutdown && AG(memory_heap)) {
HeapDestroy(AG(memory_heap));
+50
View File
@@ -85,6 +85,10 @@ ZEND_API void *_erealloc(void *ptr, size_t size, int allow_failure ZEND_FILE_LIN
ZEND_API char *_estrdup(const char *s ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
ZEND_API char *_estrndup(const char *s, unsigned int length ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
#define USE_ZEND_ALLOC 1
#if USE_ZEND_ALLOC
/* Standard wrapper macros */
#define emalloc(size) _emalloc((size) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
#define safe_emalloc(nmemb, size, offset) _safe_emalloc((nmemb), (size), (offset) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
@@ -123,6 +127,52 @@ ZEND_API char *_estrndup(const char *s, unsigned int length ZEND_FILE_LINE_DC ZE
#define safe_estrdup(ptr) ((ptr)?(estrdup(ptr)):(empty_string))
#define safe_estrndup(ptr, len) ((ptr)?(estrndup((ptr), (len))):(empty_string))
#else
#define _GNU_SOURCE
#include <string.h>
#undef _GNU_SOURCE
/* Standard wrapper macros */
#define emalloc(size) malloc(size)
#define safe_emalloc(nmemb, size, offset) malloc((nmemb) * (size) + (offset))
#define efree(ptr) free(ptr)
#define ecalloc(nmemb, size) calloc((nmemb), (size))
#define erealloc(ptr, size) realloc((ptr), (size))
#define erealloc_recoverable(ptr, size) realloc((ptr), (size))
#define estrdup(s) strdup(s)
#define estrndup(s, length) strndup((s), (length))
/* Relay wrapper macros */
#define emalloc_rel(size) malloc(size)
#define safe_emalloc_rel(nmemb, size, offset) malloc((nmemb) * (size) + (offset))
#define efree_rel(ptr) free(ptr)
#define ecalloc_rel(nmemb, size) calloc((nmemb), (size))
#define erealloc_rel(ptr, size) realloc((ptr), (size))
#define erealloc_recoverable_rel(ptr, size) realloc((ptr), (size))
#define estrdup_rel(s) strdup(s)
#define estrndup_rel(s, length) strndup((s), (length))
/* Selective persistent/non persistent allocation macros */
#define pemalloc(size, persistent) malloc(size)
#define pefree(ptr, persistent) free(ptr)
#define pecalloc(nmemb, size, persistent) calloc((nmemb), (size))
#define perealloc(ptr, size, persistent) realloc((ptr), (size))
#define perealloc_recoverable(ptr, size, persistent) realloc((ptr), (size))
#define pestrdup(s, persistent) strdup(s)
#define pemalloc_rel(size, persistent) malloc(size)
#define pefree_rel(ptr, persistent) free(ptr)
#define pecalloc_rel(nmemb, size, persistent) calloc((nmemb), (size))
#define perealloc_rel(ptr, size, persistent) realloc((ptr), (size))
#define perealloc_recoverable_rel(ptr, size, persistent) realloc((ptr), (size))
#define pestrdup_rel(s, persistent) strdup(s)
#define safe_estrdup(ptr) ((ptr)?(strdup(ptr)):(empty_string))
#define safe_estrndup(ptr, len) ((ptr)?(strndup((ptr), (len))):(empty_string))
#endif
ZEND_API int zend_set_memory_limit(unsigned int memory_limit);
ZEND_API void start_memory_manager(TSRMLS_D);
+148 -35
View File
@@ -44,6 +44,7 @@ static ZEND_FUNCTION(get_class);
static ZEND_FUNCTION(get_parent_class);
static ZEND_FUNCTION(method_exists);
static ZEND_FUNCTION(class_exists);
static ZEND_FUNCTION(interface_exists);
static ZEND_FUNCTION(function_exists);
#if ZEND_DEBUG
static ZEND_FUNCTION(leak);
@@ -102,6 +103,7 @@ static zend_function_entry builtin_functions[] = {
ZEND_FE(get_parent_class, NULL)
ZEND_FE(method_exists, NULL)
ZEND_FE(class_exists, NULL)
ZEND_FE(interface_exists, NULL)
ZEND_FE(function_exists, NULL)
#if ZEND_DEBUG
ZEND_FE(leak, NULL)
@@ -601,12 +603,21 @@ static void is_a_impl(INTERNAL_FUNCTION_PARAMETERS, zend_bool only_subclass)
ZEND_WRONG_PARAM_COUNT();
}
if (Z_TYPE_PP(obj) != IS_OBJECT) {
if (only_subclass && Z_TYPE_PP(obj) == IS_STRING) {
zend_class_entry **the_ce;
if (zend_lookup_class(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), &the_ce TSRMLS_CC) == FAILURE) {
zend_error(E_WARNING, "Unknown class passed as parameter");
RETURN_FALSE;
}
instance_ce = *the_ce;
} else if (Z_TYPE_PP(obj) != IS_OBJECT) {
RETURN_FALSE;
} else {
instance_ce = NULL;
}
/* TBI!! new object handlers */
if (!HAS_CLASS_ENTRY(**obj)) {
if (Z_TYPE_PP(obj) == IS_OBJECT && !HAS_CLASS_ENTRY(**obj)) {
RETURN_FALSE;
}
@@ -616,7 +627,11 @@ static void is_a_impl(INTERNAL_FUNCTION_PARAMETERS, zend_bool only_subclass)
retval = 0;
} else {
if (only_subclass) {
instance_ce = Z_OBJCE_PP(obj)->parent;
if (!instance_ce) {
instance_ce = Z_OBJCE_PP(obj)->parent;
} else {
instance_ce = instance_ce->parent;
}
} else {
instance_ce = Z_OBJCE_PP(obj);
}
@@ -655,30 +670,72 @@ ZEND_FUNCTION(is_a)
/* }}} */
/* {{{ add_class_vars */
static void add_class_vars(zend_class_entry *ce, HashTable *properties, zval *return_value TSRMLS_DC)
{
int instanceof = EG(scope) && instanceof_function(EG(scope), ce TSRMLS_CC);
if (zend_hash_num_elements(properties) > 0) {
HashPosition pos;
zval **prop;
zend_hash_internal_pointer_reset_ex(properties, &pos);
while (zend_hash_get_current_data_ex(properties, (void **) &prop, &pos) == SUCCESS) {
char *key, *class_name, *prop_name;
uint key_len;
ulong num_index;
zval *prop_copy;
zend_hash_get_current_key_ex(properties, &key, &key_len, &num_index, 0, &pos);
zend_hash_move_forward_ex(properties, &pos);
zend_unmangle_property_name(key, &class_name, &prop_name);
if (class_name) {
if (class_name[0] != '*' && strcmp(class_name, ce->name)) {
/* filter privates from base classes */
continue;
} else if (!instanceof) {
/* filter protected if not inside class */
continue;
}
}
/* copy: enforce read only access */
ALLOC_ZVAL(prop_copy);
*prop_copy = **prop;
zval_copy_ctor(prop_copy);
INIT_PZVAL(prop_copy);
/* this is necessary to make it able to work with default array
* properties, returned to user */
if (Z_TYPE_P(prop_copy) == IS_CONSTANT_ARRAY || Z_TYPE_P(prop_copy) == IS_CONSTANT) {
zval_update_constant(&prop_copy, 0 TSRMLS_CC);
}
add_assoc_zval(return_value, prop_name, prop_copy);
}
}
}
/* }}} */
/* {{{ proto array get_class_vars(string class_name)
Returns an array of default properties of the class */
Returns an array of default properties of the class. */
ZEND_FUNCTION(get_class_vars)
{
zval **class_name;
zend_class_entry *ce, **pce;
zval *tmp;
char *class_name;
int class_name_len;
zend_class_entry **pce;
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, &class_name)==FAILURE) {
ZEND_WRONG_PARAM_COUNT();
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &class_name, &class_name_len) == FAILURE) {
return;
}
convert_to_string_ex(class_name);
if (zend_lookup_class(Z_STRVAL_PP(class_name), Z_STRLEN_PP(class_name), &pce TSRMLS_CC) == FAILURE) {
if (zend_lookup_class(class_name, class_name_len, &pce TSRMLS_CC) == FAILURE) {
RETURN_FALSE;
} else {
ce = *pce;
array_init(return_value);
if (!ce->constants_updated) {
zend_hash_apply_with_argument(&ce->default_properties, (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
ce->constants_updated = 1;
}
zend_hash_copy(return_value->value.ht, &ce->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
add_class_vars(*pce, &(*pce)->default_properties, return_value TSRMLS_CC);
add_class_vars(*pce, (*pce)->static_members, return_value TSRMLS_CC);
}
}
/* }}} */
@@ -692,9 +749,10 @@ ZEND_FUNCTION(get_object_vars)
zval **value;
HashTable *properties;
HashPosition pos;
char *key;
char *key, *prop_name, *class_name;
uint key_len;
ulong num_index;
int instanceof;
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, &obj) == FAILURE) {
ZEND_WRONG_PARAM_COUNT();
@@ -707,16 +765,27 @@ ZEND_FUNCTION(get_object_vars)
RETURN_FALSE;
}
instanceof = EG(This) && instanceof_function(Z_OBJCE_P(EG(This)), Z_OBJCE_PP(obj) TSRMLS_CC);
array_init(return_value);
properties = Z_OBJ_HT_PP(obj)->get_properties(*obj TSRMLS_CC);
zend_hash_internal_pointer_reset_ex(properties, &pos);
while (zend_hash_get_current_data_ex(properties, (void **) &value, &pos) == SUCCESS) {
if (zend_hash_get_current_key_ex(properties, &key, &key_len, &num_index, 0, &pos) == HASH_KEY_IS_STRING && key[0]) {
if (zend_hash_get_current_key_ex(properties, &key, &key_len, &num_index, 0, &pos) == HASH_KEY_IS_STRING) {
if (key[0]) {
/* Not separating references */
(*value)->refcount++;
add_assoc_zval_ex(return_value, key, key_len, *value);
} else if (instanceof) {
zend_unmangle_property_name(key, &class_name, &prop_name);
if (!memcmp(class_name, "*", 2) || (Z_OBJCE_P(EG(This)) == Z_OBJCE_PP(obj) && !strcmp(Z_OBJCE_P(EG(This))->name, class_name))) {
/* Not separating references */
(*value)->refcount++;
add_assoc_zval_ex(return_value, prop_name, strlen(prop_name)+1, *value);
}
}
}
zend_hash_move_forward_ex(properties, &pos);
}
@@ -733,6 +802,7 @@ ZEND_FUNCTION(get_class_methods)
zend_class_entry *ce = NULL, **pce;
HashPosition pos;
zend_function *mptr;
int instanceof;
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, &class)==FAILURE) {
ZEND_WRONG_PARAM_COUNT();
@@ -754,18 +824,22 @@ ZEND_FUNCTION(get_class_methods)
RETURN_NULL();
}
instanceof = EG(scope) && instanceof_function(EG(scope), ce TSRMLS_CC);
array_init(return_value);
zend_hash_internal_pointer_reset_ex(&ce->function_table, &pos);
while (zend_hash_get_current_data_ex(&ce->function_table, (void **) &mptr, &pos) == SUCCESS) {
MAKE_STD_ZVAL(method_name);
ZVAL_STRING(method_name, mptr->common.function_name, 1);
zend_hash_next_index_insert(return_value->value.ht, &method_name, sizeof(zval *), NULL);
if ((mptr->common.fn_flags & ZEND_ACC_PUBLIC)
|| (instanceof && ((mptr->common.fn_flags & ZEND_ACC_PROTECTED) || EG(scope) == mptr->common.scope))) {
MAKE_STD_ZVAL(method_name);
ZVAL_STRING(method_name, mptr->common.function_name, 1);
zend_hash_next_index_insert(return_value->value.ht, &method_name, sizeof(zval *), NULL);
}
zend_hash_move_forward_ex(&ce->function_table, &pos);
}
}
/* }}} */
\
/* {{{ proto bool method_exists(object object, string method)
@@ -805,7 +879,7 @@ ZEND_FUNCTION(class_exists)
{
char *class_name, *lc_name;
zend_class_entry **ce;
long class_name_len;
int class_name_len;
zend_bool autoload = 1;
int found;
@@ -819,11 +893,42 @@ ZEND_FUNCTION(class_exists)
found = zend_hash_find(EG(class_table), lc_name, class_name_len+1, (void **) &ce);
free_alloca(lc_name);
RETURN_BOOL(found == SUCCESS);
RETURN_BOOL(found == SUCCESS && !((*ce)->ce_flags & ZEND_ACC_INTERFACE));
}
if (zend_lookup_class(class_name, class_name_len, &ce TSRMLS_CC) == SUCCESS) {
RETURN_TRUE;
RETURN_BOOL(((*ce)->ce_flags & ZEND_ACC_INTERFACE) == 0);
} else {
RETURN_FALSE;
}
}
/* }}} */
/* {{{ proto bool interface_exists(string classname [, bool autoload])
Checks if the class exists */
ZEND_FUNCTION(interface_exists)
{
char *iface_name, *lc_name;
zend_class_entry **ce;
int iface_name_len;
zend_bool autoload = 1;
int found;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &iface_name, &iface_name_len, &autoload) == FAILURE) {
return;
}
if (!autoload) {
lc_name = do_alloca(iface_name_len + 1);
zend_str_tolower_copy(lc_name, iface_name, iface_name_len);
found = zend_hash_find(EG(class_table), lc_name, iface_name_len+1, (void **) &ce);
free_alloca(lc_name);
RETURN_BOOL(found == SUCCESS && (*ce)->ce_flags & ZEND_ACC_INTERFACE);
}
if (zend_lookup_class(iface_name, iface_name_len, &ce TSRMLS_CC) == SUCCESS) {
RETURN_BOOL(((*ce)->ce_flags & ZEND_ACC_INTERFACE) > 0);
} else {
RETURN_FALSE;
}
@@ -960,7 +1065,7 @@ ZEND_FUNCTION(set_error_handler)
zval *error_handler;
zend_bool had_orig_error_handler=0;
char *error_handler_name = NULL;
long error_type = E_ALL;
long error_type = E_ALL | E_STRICT;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|l", &error_handler, &error_type) == FAILURE) {
return;
@@ -1035,13 +1140,15 @@ ZEND_FUNCTION(set_exception_handler)
ZEND_WRONG_PARAM_COUNT();
}
if (!zend_is_callable(*exception_handler, 0, &exception_handler_name)) {
zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback",
get_active_function_name(TSRMLS_C), exception_handler_name?exception_handler_name:"unknown");
if (Z_TYPE_PP(exception_handler) != IS_NULL) { /* NULL == unset */
if (!zend_is_callable(*exception_handler, 0, &exception_handler_name)) {
zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback",
get_active_function_name(TSRMLS_C), exception_handler_name?exception_handler_name:"unknown");
efree(exception_handler_name);
return;
}
efree(exception_handler_name);
return;
}
efree(exception_handler_name);
if (EG(user_exception_handler)) {
had_orig_exception_handler = 1;
@@ -1051,7 +1158,7 @@ ZEND_FUNCTION(set_exception_handler)
}
ALLOC_ZVAL(EG(user_exception_handler));
if (Z_STRLEN_PP(exception_handler)==0) { /* unset user-defined handler */
if (Z_TYPE_PP(exception_handler) == IS_NULL) { /* unset user-defined handler */
FREE_ZVAL(EG(user_exception_handler));
EG(user_exception_handler) = NULL;
RETURN_TRUE;
@@ -1484,6 +1591,7 @@ ZEND_FUNCTION(debug_print_backtrace)
array_init(return_value);
while (ptr) {
class_name = call_type = NULL;
if (ptr->op_array) {
filename = ptr->op_array->filename;
lineno = ptr->opline->lineno;
@@ -1597,11 +1705,11 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last TSRML
ptr = EG(current_execute_data);
/* skip debug_backtrace() */
ptr = ptr->prev_execute_data;
if (skip_last--) {
int arg_count = *((ulong*)(cur_arg_pos - 2));
cur_arg_pos -= (arg_count + 2);
frames_on_stack--;
ptr = ptr->prev_execute_data;
}
array_init(return_value);
@@ -1654,6 +1762,11 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last TSRML
/* i know this is kinda ugly, but i'm trying to avoid extra cycles in the main execution loop */
zend_bool build_filename_arg = 1;
if (!ptr->opline) {
/* can happen when calling eval from a custom sapi */
function_name = "unknown";
build_filename_arg = 0;
} else
switch (ptr->opline->op2.u.constant.value.lval) {
case ZEND_EVAL:
function_name = "eval";
+74 -60
View File
@@ -761,6 +761,9 @@ void zend_do_end_variable_parse(int type, int arg_offset TSRMLS_DC)
opline->opcode += 3;
break;
case BP_VAR_IS:
if (opline->opcode == ZEND_FETCH_DIM_W && opline->op2.op_type == IS_UNUSED) {
zend_error(E_COMPILE_ERROR, "Cannot use [] for reading");
}
opline->opcode += 6; /* 3+3 */
break;
case BP_VAR_FUNC_ARG:
@@ -992,35 +995,37 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n
fn_flags |= ZEND_ACC_PUBLIC;
}
short_class_name = do_alloca(short_class_name_length + 1);
zend_str_tolower_copy(short_class_name, CG(active_class_entry)->name, short_class_name_length);
/* Improve after RC: cache the lowercase class name */
if ((short_class_name_length == name_len) && (!memcmp(short_class_name, 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)->ce_flags & ZEND_ACC_INTERFACE)) {
short_class_name = do_alloca(short_class_name_length + 1);
zend_str_tolower_copy(short_class_name, CG(active_class_entry)->name, short_class_name_length);
/* Improve after RC: cache the lowercase class name */
if ((short_class_name_length == name_len) && (!memcmp(short_class_name, 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 {
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)))) {
if (CG(active_class_entry)->constructor) {
zend_error(E_STRICT, "Redefining already defined constructor for class %s", CG(active_class_entry)->name);
}
CG(active_class_entry)->constructor = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_DESTRUCTOR_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_DESTRUCTOR_FUNC_NAME, sizeof(ZEND_DESTRUCTOR_FUNC_NAME)))) {
CG(active_class_entry)->destructor = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_CLONE_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_CLONE_FUNC_NAME, sizeof(ZEND_CLONE_FUNC_NAME)))) {
CG(active_class_entry)->clone = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_CALL_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_CALL_FUNC_NAME, sizeof(ZEND_CALL_FUNC_NAME)))) {
CG(active_class_entry)->__call = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_GET_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_GET_FUNC_NAME, sizeof(ZEND_GET_FUNC_NAME)))) {
CG(active_class_entry)->__get = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_SET_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_SET_FUNC_NAME, sizeof(ZEND_SET_FUNC_NAME)))) {
CG(active_class_entry)->__set = (zend_function *) CG(active_op_array);
} else if (!(fn_flags & ZEND_ACC_STATIC)) {
CG(active_op_array)->fn_flags |= ZEND_ACC_ALLOW_STATIC;
}
} else if ((name_len == sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_CONSTRUCTOR_FUNC_NAME, sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)))) {
if (CG(active_class_entry)->constructor) {
zend_error(E_STRICT, "Redefining already defined constructor for class %s", CG(active_class_entry)->name);
}
CG(active_class_entry)->constructor = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_DESTRUCTOR_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_DESTRUCTOR_FUNC_NAME, sizeof(ZEND_DESTRUCTOR_FUNC_NAME)))) {
CG(active_class_entry)->destructor = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_CLONE_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_CLONE_FUNC_NAME, sizeof(ZEND_CLONE_FUNC_NAME)))) {
CG(active_class_entry)->clone = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_CALL_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_CALL_FUNC_NAME, sizeof(ZEND_CALL_FUNC_NAME)))) {
CG(active_class_entry)->__call = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_GET_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_GET_FUNC_NAME, sizeof(ZEND_GET_FUNC_NAME)))) {
CG(active_class_entry)->__get = (zend_function *) CG(active_op_array);
} else if ((name_len == sizeof(ZEND_SET_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_SET_FUNC_NAME, sizeof(ZEND_SET_FUNC_NAME)))) {
CG(active_class_entry)->__set = (zend_function *) CG(active_op_array);
} else if (!(fn_flags & ZEND_ACC_STATIC)) {
CG(active_op_array)->fn_flags |= ZEND_ACC_ALLOW_STATIC;
free_alloca(short_class_name);
}
free_alloca(short_class_name);
efree(lcname);
} else {
@@ -1087,16 +1092,26 @@ void zend_do_handle_exception(TSRMLS_D)
void zend_do_end_function_declaration(znode *function_token TSRMLS_DC)
{
char lcname[16];
int name_len;
zend_do_extended_info(TSRMLS_C);
zend_do_return(NULL, 0 TSRMLS_CC);
zend_do_handle_exception(TSRMLS_C);
pass_two(CG(active_op_array) TSRMLS_CC);
if (CG(active_class_entry)
&& !strcmp(CG(active_op_array)->function_name, ZEND_CLONE_FUNC_NAME)
&& CG(active_op_array)->num_args != 0) {
zend_error(E_COMPILE_ERROR, "The clone method cannot accept any arguments");
if (CG(active_class_entry)) {
zend_check_magic_method_implementation(CG(active_class_entry), (zend_function*)CG(active_op_array), E_COMPILE_ERROR TSRMLS_CC);
} else {
/* we don't care if the function name is longer, in fact lowercasing only
* the beginning of the name speeds up the check process */
name_len = strlen(CG(active_op_array)->function_name);
zend_str_tolower_copy(lcname, CG(active_op_array)->function_name, MIN(name_len, sizeof(lcname)-1));
lcname[sizeof(lcname)-1] = '\0'; /* zend_str_tolower_copy won't necessarily set the zero byte */
if (name_len == sizeof(ZEND_AUTOLOAD_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_AUTOLOAD_FUNC_NAME, sizeof(ZEND_AUTOLOAD_FUNC_NAME)) && CG(active_op_array)->num_args != 1) {
zend_error(E_COMPILE_ERROR, "%s() must take exactly 1 argument", ZEND_AUTOLOAD_FUNC_NAME);
}
}
CG(active_op_array)->line_end = zend_get_compiled_lineno(TSRMLS_C);
@@ -1114,10 +1129,6 @@ void zend_do_receive_arg(zend_uchar op, znode *var, znode *offset, znode *initia
zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC);
zend_arg_info *cur_arg_info;
if (CG(active_class_entry) && CG(active_class_entry)->destructor == (zend_function *) CG(active_op_array))
{
zend_error(E_COMPILE_ERROR, "Destuctor %s::%s() cannot take arguments", CG(active_class_entry)->name, CG(active_op_array)->function_name);
}
CG(active_op_array)->num_args++;
opline->opcode = op;
opline->result = *var;
@@ -1193,7 +1204,7 @@ void zend_do_begin_method_call(znode *left_bracket TSRMLS_DC)
last_op_number = get_next_op_number(CG(active_op_array))-1;
last_op = &CG(active_op_array)->opcodes[last_op_number];
if ((last_op->op2.op_type == IS_CONST) && (last_op->op2.u.constant.value.str.len == sizeof(ZEND_CLONE_FUNC_NAME)-1)
if ((last_op->op2.op_type == IS_CONST) && (last_op->op2.u.constant.type == IS_STRING) && (last_op->op2.u.constant.value.str.len == sizeof(ZEND_CLONE_FUNC_NAME)-1)
&& !zend_binary_strcasecmp(last_op->op2.u.constant.value.str.val, last_op->op2.u.constant.value.str.len, ZEND_CLONE_FUNC_NAME, sizeof(ZEND_CLONE_FUNC_NAME)-1)) {
zend_error(E_COMPILE_ERROR, "Cannot call __clone() method on objects - use 'clone $obj' instead");
}
@@ -1298,36 +1309,27 @@ void zend_do_fetch_class_name(znode *result, znode *class_name_entry, znode *cla
result->u.constant.value.str.len = length;
}
void zend_do_begin_class_member_function_call(TSRMLS_D)
void zend_do_begin_class_member_function_call(znode *class_name, znode *method_name TSRMLS_DC)
{
unsigned char *ptr = NULL;
long fetch_const_op_number = get_next_op_number(CG(active_op_array));
zend_op *last_op = &CG(active_op_array)->opcodes[fetch_const_op_number-1];
zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC);
if (last_op->opcode == ZEND_FETCH_CONSTANT) { /* regular method call */
/* a tmp var is leaked here */
last_op->opcode = ZEND_INIT_STATIC_METHOD_CALL;
if(last_op->op2.op_type == IS_CONST &&
(sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) == Z_STRLEN(last_op->op2.u.constant) &&
memcmp(Z_STRVAL(last_op->op2.u.constant), ZEND_CONSTRUCTOR_FUNC_NAME, sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) == 0) {
zval_dtor(&last_op->op2.u.constant);
SET_UNUSED(last_op->op2);
opline->opcode = ZEND_INIT_STATIC_METHOD_CALL;
opline->op1 = *class_name;
opline->op2 = *method_name;
if (opline->op2.op_type == IS_CONST) {
if ((sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) == Z_STRLEN(opline->op2.u.constant) &&
memcmp(Z_STRVAL(opline->op2.u.constant), ZEND_CONSTRUCTOR_FUNC_NAME, sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) == 0) {
zval_dtor(&opline->op2.u.constant);
SET_UNUSED(opline->op2);
} else {
zend_lowercase_znode_if_const(&last_op->op2);
zend_str_tolower(opline->op2.u.constant.value.str.val, opline->op2.u.constant.value.str.len);
}
} else if (last_op->opcode == ZEND_FETCH_R) { /* indirect method call */
zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC);
last_op->op2.u.EA.type = ZEND_FETCH_LOCAL;
opline->opcode = ZEND_INIT_STATIC_METHOD_CALL;
opline->op1 = last_op->op2;
opline->op2 = last_op->result;
} else {
zend_error(E_COMPILE_ERROR, "Internal compiler error - please report!");
}
zend_stack_push(&CG(function_call_stack), (void *) &ptr, sizeof(zend_function *));
zend_do_extended_fcall_begin(TSRMLS_C);
}
@@ -1675,9 +1677,11 @@ static void do_inherit_parent_constructor(zend_class_entry *ce)
if (!zend_hash_exists(&ce->function_table, lc_class_name, ce->name_length+1)) {
lc_parent_class_name = zend_str_tolower_dup(ce->parent->name, ce->parent->name_length);
if (zend_hash_find(&ce->parent->function_table, lc_parent_class_name, ce->parent->name_length+1, (void **)&function)==SUCCESS) {
/* inherit parent's constructor */
zend_hash_update(&ce->function_table, lc_class_name, ce->name_length+1, function, sizeof(zend_function), NULL);
function_add_ref(function);
if (function->common.fn_flags & ZEND_ACC_CTOR) {
/* inherit parent's constructor */
zend_hash_update(&ce->function_table, lc_class_name, ce->name_length+1, function, sizeof(zend_function), NULL);
function_add_ref(function);
}
}
efree(lc_parent_class_name);
}
@@ -1924,6 +1928,9 @@ static inline void do_implement_interface(zend_class_entry *ce, zend_class_entry
if (!(ce->ce_flags & ZEND_ACC_INTERFACE) && iface->interface_gets_implemented && iface->interface_gets_implemented(iface, ce TSRMLS_CC) == FAILURE) {
zend_error(E_CORE_ERROR, "Class %s could not implement interface %s", ce->name, iface->name);
}
if (ce == iface) {
zend_error(E_ERROR, "Interface %s cannot not implement itself", ce->name);
}
}
@@ -1993,6 +2000,8 @@ void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent_ce TSRML
zend_hash_merge(&ce->constants_table, &parent_ce->constants_table, (void (*)(void *)) zval_add_ref, 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);
zend_verify_abstract_class(ce TSRMLS_CC);
}
@@ -2100,6 +2109,10 @@ ZEND_API zend_class_entry *do_bind_inherited_class(zend_op *opline, HashTable *c
ce = *pce;
}
if (parent_ce->ce_flags & ZEND_ACC_INTERFACE) {
zend_error(E_COMPILE_ERROR, "Class %s cannot extend from interface %s", ce->name, parent_ce->name);
}
zend_do_inheritance(ce, parent_ce TSRMLS_CC);
ce->refcount++;
@@ -3746,6 +3759,7 @@ ZEND_API void zend_initialize_class_data(zend_class_entry *ce, zend_bool nullify
ce->parent = NULL;
ce->num_interfaces = 0;
ce->interfaces = NULL;
ce->module = NULL;
}
}
+4 -2
View File
@@ -375,7 +375,7 @@ void zend_do_clone(znode *result, znode *expr TSRMLS_DC);
void zend_do_begin_dynamic_function_call(znode *function_name TSRMLS_DC);
void zend_do_fetch_class(znode *result, znode *class_name TSRMLS_DC);
void zend_do_fetch_class_name(znode *result, znode *class_entry, znode *class_name TSRMLS_DC);
void zend_do_begin_class_member_function_call(TSRMLS_D);
void zend_do_begin_class_member_function_call(znode *class_name, znode *method_name TSRMLS_DC);
void zend_do_end_function_call(znode *function_name, znode *result, znode *argument_list, int is_method, int is_dynamic_fcall TSRMLS_DC);
void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC);
void zend_do_handle_exception(TSRMLS_D);
@@ -494,13 +494,14 @@ ZEND_API int zend_cleanup_class_data(zend_class_entry **pce TSRMLS_DC);
ZEND_API int zend_cleanup_function_data(zend_function *function TSRMLS_DC);
ZEND_API void destroy_zend_function(zend_function *function TSRMLS_DC);
ZEND_API void zend_function_dtor(zend_function *function);
ZEND_API void destroy_zend_class(zend_class_entry **pce);
void zend_class_add_ref(zend_class_entry **ce);
ZEND_API void zend_mangle_property_name(char **dest, int *dest_length, char *src1, int src1_length, char *src2, int src2_length, int internal);
ZEND_API void zend_unmangle_property_name(char *mangled_property, char **prop_name, char **class_name);
#define ZEND_FUNCTION_DTOR (void (*)(void *)) destroy_zend_function
#define ZEND_FUNCTION_DTOR (void (*)(void *)) zend_function_dtor
#define ZEND_CLASS_DTOR (void (*)(void *)) destroy_zend_class
zend_op *get_next_op(zend_op_array *op_array TSRMLS_DC);
@@ -839,6 +840,7 @@ END_EXTERN_C()
#define ZEND_GET_FUNC_NAME "__get"
#define ZEND_SET_FUNC_NAME "__set"
#define ZEND_CALL_FUNC_NAME "__call"
#define ZEND_AUTOLOAD_FUNC_NAME "__autoload"
#endif /* ZEND_COMPILE_H */
+1
View File
@@ -55,6 +55,7 @@ typedef unsigned int uint;
#define HAVE_STDARG_H 1
#define HAVE_SNPRINTF 1
#define HAVE_VSNPRINTF 1
#define HAVE_STRCOLL 1
#define snprintf _snprintf
#define vsnprintf _vsnprintf
+10 -13
View File
@@ -231,10 +231,8 @@ ZEND_API int zend_get_constant(char *name, uint name_len, zval *result TSRMLS_DC
scope = CG(active_class_entry);
}
class_name = do_alloca(class_name_len+1);
memcpy(class_name, name, class_name_len);
class_name[class_name_len] = '\0';
class_name = estrndup(name, class_name_len);
if (class_name_len == sizeof("self")-1 && strcmp(class_name, "self") == 0) {
if (scope) {
ce = &scope;
@@ -255,7 +253,7 @@ ZEND_API int zend_get_constant(char *name, uint name_len, zval *result TSRMLS_DC
retval = 0;
}
}
free_alloca(class_name);
efree(class_name);
if (retval && ce) {
if (zend_hash_find(&((*ce)->constants_table), constant_name, const_name_len+1, (void **) &ret_constant) != SUCCESS) {
@@ -275,9 +273,8 @@ ZEND_API int zend_get_constant(char *name, uint name_len, zval *result TSRMLS_DC
}
if (zend_hash_find(EG(zend_constants), name, name_len+1, (void **) &c) == FAILURE) {
lookup_name = do_alloca(name_len+1);
zend_str_tolower_copy(lookup_name, name, name_len);
lookup_name[name_len] = '\0';
lookup_name = estrndup(name, name_len);
zend_str_tolower(lookup_name, name_len);
if (zend_hash_find(EG(zend_constants), lookup_name, name_len+1, (void **) &c)==SUCCESS) {
if ((c->flags & CONST_CS) && memcmp(c->name, name, name_len)!=0) {
@@ -286,7 +283,7 @@ ZEND_API int zend_get_constant(char *name, uint name_len, zval *result TSRMLS_DC
} else {
retval=0;
}
free_alloca(lookup_name);
efree(lookup_name);
}
if (retval) {
@@ -312,23 +309,23 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC)
if (!(c->flags & CONST_CS)) {
/* keep in mind that c->name_len already contains the '\0' */
lowercase_name = do_alloca(c->name_len);
zend_str_tolower_copy(lowercase_name, c->name, c->name_len - 1);
lowercase_name = estrndup(c->name, c->name_len);
zend_str_tolower(lowercase_name, c->name_len);
name = lowercase_name;
} else {
name = c->name;
}
if (zend_hash_add(EG(zend_constants), name, c->name_len, (void *) c, sizeof(zend_constant), NULL)==FAILURE) {
zend_error(E_NOTICE,"Constant %s already defined", name);
free(c->name);
if (!(c->flags & CONST_PERSISTENT)) {
zval_dtor(&c->value);
}
zend_error(E_NOTICE,"Constant %s already defined", name);
ret = FAILURE;
}
if (lowercase_name) {
free_alloca(lowercase_name);
efree(lowercase_name);
}
return ret;
}
+1 -1
View File
@@ -30,7 +30,7 @@ typedef struct _dynamic_array {
} dynamic_array;
BEGIN_EXTERN_C()
ZEND_API int zend_dynamic_array_init(dynamic_array *da);
ZEND_API int zend_dynamic_array_init(dynamic_array *da, unsigned int element_size, unsigned int size);
ZEND_API void *zend_dynamic_array_push(dynamic_array *da);
ZEND_API void *zend_dynamic_array_pop(dynamic_array *da);
ZEND_API void *zend_dynamic_array_get_element(dynamic_array *da, unsigned int index);
+9 -2
View File
@@ -50,7 +50,8 @@ void zend_throw_exception_internal(zval *exception TSRMLS_DC)
zend_throw_exception_hook(exception TSRMLS_CC);
}
if ((EG(current_execute_data)->opline+1)->opcode == ZEND_HANDLE_EXCEPTION) {
if (EG(current_execute_data)->opline == NULL ||
(EG(current_execute_data)->opline+1)->opcode == ZEND_HANDLE_EXCEPTION) {
/* no need to rethrow the exception */
return;
}
@@ -427,9 +428,15 @@ ZEND_METHOD(exception, __toString)
* And never try to change the state of exceptions and never implement anything
* that gives the user anything to accomplish this.
*/
static
ZEND_BEGIN_ARG_INFO(arginfo_exception___construct, 0)
ZEND_ARG_INFO(0, message)
ZEND_ARG_INFO(0, code)
ZEND_END_ARG_INFO();
static zend_function_entry default_exception_functions[] = {
ZEND_ME(exception, __clone, NULL, ZEND_ACC_PRIVATE|ZEND_ACC_FINAL)
ZEND_ME(exception, __construct, NULL, 0)
ZEND_ME(exception, __construct, arginfo_exception___construct, ZEND_ACC_PUBLIC)
ZEND_ME(exception, getMessage, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
ZEND_ME(exception, getCode, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
ZEND_ME(exception, getFile, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
+43 -24
View File
@@ -52,6 +52,7 @@ static void zend_extension_fcall_end_handler(zend_extension *extension, zend_op_
#define EX_T(offset) (*(temp_variable *)((char *) EX(Ts) + offset))
#define T(offset) (*(temp_variable *)((char *) Ts + offset))
#define TEMP_VAR_STACK_LIMIT 2000
/* former zend_execute_locks.h */
static inline void zend_pzval_lock_func(zval *z)
@@ -377,7 +378,7 @@ static inline void zend_assign_to_object(znode *result, zval **object_ptr, znode
*retval = EG(uninitialized_zval_ptr);
SELECTIVE_PZVAL_LOCK(*retval, result);
PZVAL_UNLOCK(value);
FREE_OP(Ts, value_op, free_value);
return;
}
@@ -839,8 +840,10 @@ fetch_string_dim:
}
}
break;
case IS_DOUBLE:
case IS_RESOURCE:
zend_error(E_STRICT, "Resource ID#%ld used as offset, casting to integer (%ld)", dim->value.lval, dim->value.lval);
/* Fall Through */
case IS_DOUBLE:
case IS_BOOL:
case IS_LONG: {
long index;
@@ -1275,11 +1278,9 @@ static void zend_post_incdec_property(znode *result, znode *op1, znode *op2, tem
*retval = *z;
zendi_zval_copy_ctor(*retval);
incdec_op(z);
z->refcount++;
Z_OBJ_HT_P(object)->write_property(object, property, z TSRMLS_CC);
if (z->refcount == 0) {
zval_dtor(z);
FREE_ZVAL(z);
}
zval_ptr_dtor(&z);
}
FREE_OP(Ts, op2, EG(free_op2));
@@ -1330,7 +1331,11 @@ static int zend_check_symbol(zval **pz TSRMLS_DC)
}
#define RETURN_FROM_EXECUTE_LOOP(execute_data) \
free_alloca(EX(Ts)); \
if (EX(op_array)->T < TEMP_VAR_STACK_LIMIT) { \
free_alloca(EX(Ts)); \
} else { \
efree(EX(Ts)); \
} \
EG(in_execution) = EX(original_in_execution); \
EG(current_execute_data) = EX(prev_execute_data); \
return 1; /* CHECK_ME */
@@ -1349,7 +1354,11 @@ ZEND_API void execute(zend_op_array *op_array TSRMLS_DC)
/* Initialize execute_data */
EX(fbc) = NULL;
EX(object) = NULL;
EX(Ts) = (temp_variable *) do_alloca(sizeof(temp_variable)*op_array->T);
if (op_array->T < TEMP_VAR_STACK_LIMIT) {
EX(Ts) = (temp_variable *) do_alloca(sizeof(temp_variable) * op_array->T);
} else {
EX(Ts) = (temp_variable *) safe_emalloc(sizeof(temp_variable), op_array->T, 0);
}
EX(op_array) = op_array;
EX(original_in_execution) = EG(in_execution);
EX(prev_execute_data) = EG(current_execute_data);
@@ -1766,6 +1775,9 @@ static inline int zend_binary_assign_op_helper(int (*binary_op)(zval *result, zv
EX_T(opline->result.u.var).var.ptr_ptr = &EG(uninitialized_zval_ptr);
SELECTIVE_PZVAL_LOCK(*EX_T(opline->result.u.var).var.ptr_ptr, &opline->result);
AI_USE_PTR(EX_T(opline->result.u.var).var);
if (increment_opline) {
INC_OPCODE();
}
NEXT_OPCODE();
}
@@ -2777,6 +2789,9 @@ int zend_do_fcall_common_helper(ZEND_OPCODE_HANDLER_ARGS)
if (EG(This)) {
if (EG(exception) && EX(fbc) && EX(fbc)->common.fn_flags&ZEND_ACC_CTOR) {
EG(This)->refcount--;
if (EG(This)->refcount == 1) {
zend_object_store_ctor_failed(EG(This) TSRMLS_CC);
}
zval_ptr_dtor(&EG(This));
} else if (should_change_scope) {
zval_ptr_dtor(&EG(This));
@@ -2929,21 +2944,16 @@ int zend_catch_handler(ZEND_OPCODE_HANDLER_ARGS)
}
ce = Z_OBJCE_P(EG(exception));
if (ce != EX_T(opline->op1.u.var).class_entry) {
while (ce->parent) {
if (ce->parent == EX_T(opline->op1.u.var).class_entry) {
goto exception_should_be_taken;
if (!instanceof_function(ce, EX_T(opline->op1.u.var).class_entry TSRMLS_CC)) {
if (opline->op1.u.EA.type) {
zend_throw_exception_internal(NULL TSRMLS_CC);
NEXT_OPCODE();
}
ce = ce->parent;
SET_OPCODE(&op_array->opcodes[opline->extended_value]);
return 0; /* CHECK_ME */
}
if (opline->op1.u.EA.type) {
zend_throw_exception_internal(NULL TSRMLS_CC);
NEXT_OPCODE();
}
SET_OPCODE(&op_array->opcodes[opline->extended_value]);
return 0; /* CHECK_ME */
}
exception_should_be_taken:
zend_hash_update(EG(active_symbol_table), opline->op2.u.constant.value.str.val,
opline->op2.u.constant.value.str.len+1, &EG(exception), sizeof(zval *), (void **) NULL);
EG(exception) = NULL;
@@ -3404,6 +3414,7 @@ static inline int zend_init_add_array_helper(ZEND_OPCODE_HANDLER_ARGS)
zend_hash_update(array_ptr->value.ht, "", sizeof(""), &expr_ptr, sizeof(zval *), NULL);
break;
default:
zend_error(E_WARNING, "Illegal offset type");
zval_ptr_dtor(&expr_ptr);
/* do nothing */
break;
@@ -3661,7 +3672,7 @@ int zend_unset_dim_obj_handler(ZEND_OPCODE_HANDLER_ARGS)
case IS_BOOL:
case IS_LONG:
if (offset->type == IS_DOUBLE) {
index = (long) offset->value.lval;
index = (long) offset->value.dval;
} else {
index = offset->value.lval;
}
@@ -3698,7 +3709,7 @@ int zend_fe_reset_handler(ZEND_OPCODE_HANDLER_ARGS)
if (opline->extended_value) {
array_ptr_ptr = get_zval_ptr_ptr(&opline->op1, EX(Ts), BP_VAR_R);
if (array_ptr_ptr == NULL) {
MAKE_STD_ZVAL(array_ptr);
ALLOC_INIT_ZVAL(array_ptr);
} else if (Z_TYPE_PP(array_ptr_ptr) == IS_OBJECT) {
ce = Z_OBJCE_PP(array_ptr_ptr);
if (!ce || ce->get_iterator == NULL) {
@@ -3796,7 +3807,7 @@ int zend_fe_fetch_handler(ZEND_OPCODE_HANDLER_ARGS)
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
zend_hash_move_forward(fe_ht);
} while (zend_check_property_access(zobj, str_key TSRMLS_CC) != SUCCESS);
} while (key_type != HASH_KEY_IS_STRING || zend_check_property_access(zobj, str_key TSRMLS_CC) != SUCCESS);
zend_unmangle_property_name(str_key, &class_name, &prop_name);
str_key_len = strlen(prop_name);
str_key = estrndup(prop_name, str_key_len);
@@ -4022,14 +4033,22 @@ static int zend_isset_isempty_dim_prop_obj_handler(int prop_dim, ZEND_OPCODE_HAN
result = Z_OBJ_HT_P(*container)->has_dimension(*container, offset, (opline->extended_value == ZEND_ISEMPTY) TSRMLS_CC);
}
} else if ((*container)->type == IS_STRING) { /* string offsets */
zval tmp_offset;
if (Z_TYPE_P(offset) != IS_LONG) {
tmp_offset = *offset;
zval_copy_ctor(&tmp_offset);
convert_to_long(&tmp_offset);
offset = &tmp_offset;
}
switch (opline->extended_value) {
case ZEND_ISSET:
if (offset->value.lval <= Z_STRLEN_PP(container)) {
if (offset->value.lval >= 0 && offset->value.lval < Z_STRLEN_PP(container)) {
result = 1;
}
break;
case ZEND_ISEMPTY:
if (offset->value.lval <= Z_STRLEN_PP(container) && Z_STRVAL_PP(container)[offset->value.lval] != '0') {
if (offset->value.lval >= 0 && offset->value.lval < Z_STRLEN_PP(container) && Z_STRVAL_PP(container)[offset->value.lval] != '0') {
result = 1;
}
break;
+10 -5
View File
@@ -183,8 +183,6 @@ void init_executor(TSRMLS_D)
EG(scope) = NULL;
EG(This) = NULL;
EG(float_separator)[0] = '.';
}
void shutdown_executor(TSRMLS_D)
@@ -208,6 +206,9 @@ void shutdown_executor(TSRMLS_D)
zend_llist_apply(&zend_extensions, (llist_apply_func_t) zend_extension_deactivator TSRMLS_CC);
zend_objects_store_call_destructors(&EG(objects_store) TSRMLS_CC);
zend_hash_graceful_reverse_destroy(&EG(symbol_table));
} zend_catch {
/* if we couldn't destruct cleanly, mark all objects as destructed anyway */
zend_objects_store_mark_destructed(&EG(objects_store) TSRMLS_CC);
} zend_end_try();
zend_try {
@@ -684,7 +685,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
zend_error(E_ERROR, "Object does not support method calls");
}
EX(function_state).function =
Z_OBJ_HT_PP(fci->object_pp)->get_method(*fci->object_pp, Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name) TSRMLS_CC);
Z_OBJ_HT_PP(fci->object_pp)->get_method(*fci->object_pp, Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name) TSRMLS_CC);
} else if (calling_scope) {
char *function_name_lc = zend_str_tolower_dup(Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name));
@@ -885,6 +886,10 @@ ZEND_API int zend_lookup_class(char *name, int name_length, zend_class_entry ***
zval *exception;
char dummy = 1;
if (name == NULL) {
return FAILURE;
}
lc_name = do_alloca(name_length + 1);
zend_str_tolower_copy(lc_name, name, name_length);
@@ -911,7 +916,7 @@ ZEND_API int zend_lookup_class(char *name, int name_length, zend_class_entry ***
return FAILURE;
}
ZVAL_STRINGL(&autoload_function, "__autoload", sizeof("__autoload")-1, 0);
ZVAL_STRINGL(&autoload_function, ZEND_AUTOLOAD_FUNC_NAME, sizeof(ZEND_AUTOLOAD_FUNC_NAME)-1, 0);
INIT_PZVAL(class_name_ptr);
ZVAL_STRINGL(class_name_ptr, name, name_length, 0);
@@ -932,7 +937,7 @@ ZEND_API int zend_lookup_class(char *name, int name_length, zend_class_entry ***
if (EG(exception)) {
free_alloca(lc_name);
zend_error(E_ERROR, "__autoload(%s) threw an exception of type '%s'", name, Z_OBJCE_P(EG(exception))->name);
zend_error(E_ERROR, "Function %s(%s) threw an exception of type '%s'", ZEND_AUTOLOAD_FUNC_NAME, name, Z_OBJCE_P(EG(exception))->name);
return FAILURE;
}
EG(exception) = exception;
-3
View File
@@ -237,9 +237,6 @@ struct _zend_executor_globals {
zend_property_info std_property_info;
/* locale stuff */
char float_separator[1];
void *reserved[ZEND_MAX_RESERVED_RESOURCES];
};
+17 -11
View File
@@ -137,6 +137,7 @@ ZEND_API ulong zend_hash_func(char *arKey, uint nKeyLength)
ZEND_API int _zend_hash_init(HashTable *ht, uint nSize, hash_func_t pHashFunction, dtor_func_t pDestructor, zend_bool persistent ZEND_FILE_LINE_DC)
{
uint i = 3;
Bucket **tmp;
SET_INCONSISTENT(HT_OK);
@@ -146,18 +147,8 @@ ZEND_API int _zend_hash_init(HashTable *ht, uint nSize, hash_func_t pHashFunctio
ht->nTableSize = 1 << i;
ht->nTableMask = ht->nTableSize - 1;
/* Uses ecalloc() so that Bucket* == NULL */
if (persistent) {
ht->arBuckets = (Bucket **) calloc(ht->nTableSize, sizeof(Bucket *));
if (!ht->arBuckets) {
return FAILURE;
}
} else {
ht->arBuckets = (Bucket **) ecalloc_rel(ht->nTableSize, sizeof(Bucket *));
}
ht->pDestructor = pDestructor;
ht->arBuckets = NULL;
ht->pListHead = NULL;
ht->pListTail = NULL;
ht->nNumOfElements = 0;
@@ -166,6 +157,21 @@ ZEND_API int _zend_hash_init(HashTable *ht, uint nSize, hash_func_t pHashFunctio
ht->persistent = persistent;
ht->nApplyCount = 0;
ht->bApplyProtection = 1;
/* Uses ecalloc() so that Bucket* == NULL */
if (persistent) {
tmp = (Bucket **) calloc(ht->nTableSize, sizeof(Bucket *));
if (!tmp) {
return FAILURE;
}
ht->arBuckets = tmp;
} else {
tmp = (Bucket **) ecalloc_rel(ht->nTableSize, sizeof(Bucket *));
if (tmp) {
ht->arBuckets = tmp;
}
}
return SUCCESS;
}
+10 -4
View File
@@ -159,6 +159,12 @@ ZEND_API void zend_highlight(zend_syntax_highlighter_ini *syntax_highlighter_ini
switch (token_type) {
case T_END_HEREDOC:
zend_html_puts(token.value.str.val, token.value.str.len TSRMLS_CC);
{
char *ptr = LANG_SCNG(yy_text);
if (ptr[LANG_SCNG(yy_leng) - 1] != ';') {
zend_html_putc('\n');
}
}
break;
default:
zend_html_puts(LANG_SCNG(yy_text), LANG_SCNG(yy_leng) TSRMLS_CC);
@@ -203,7 +209,7 @@ ZEND_API void zend_strip(TSRMLS_D)
switch (token_type) {
case T_WHITESPACE:
if (!prev_space) {
putchar(' ');
zend_write(" ", sizeof(" ") - 1);
prev_space = 1;
}
/* lack of break; is intentional */
@@ -215,9 +221,9 @@ ZEND_API void zend_strip(TSRMLS_D)
case T_END_HEREDOC: {
char *ptr = LANG_SCNG(yy_text);
fwrite(ptr, LANG_SCNG(yy_leng) - 1, 1, stdout);
zend_write(ptr, LANG_SCNG(yy_leng) - 1);
/* The ensure that we only write one ; and that it followed by the required newline */
putchar('\n');
zend_write("\n", sizeof("\n") - 1);
if (ptr[LANG_SCNG(yy_leng) - 1] == ';') {
lex_scan(&token TSRMLS_CC);
}
@@ -226,7 +232,7 @@ ZEND_API void zend_strip(TSRMLS_D)
break;
default:
fwrite(LANG_SCNG(yy_text), LANG_SCNG(yy_leng), 1, stdout);
zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng));
break;
}
+20 -4
View File
@@ -24,6 +24,7 @@
#include "zend_ini.h"
#include "zend_alloc.h"
#include "zend_operators.h"
#include "zend_strtod.h"
static HashTable *registered_zend_ini_directives;
@@ -147,10 +148,25 @@ ZEND_API int zend_register_ini_entries(zend_ini_entry *ini_entry, int module_num
zend_ini_entry *p = ini_entry;
zend_ini_entry *hashed_ini_entry;
zval default_value;
HashTable *directives = registered_zend_ini_directives;
#ifdef ZTS
/* if we are called during the request, eg: from dl(),
* then we should not touch the global directives table,
* and should update the per-(request|thread) version instead.
* This solves two problems: one is that ini entries for dl()'d
* extensions will now work, and the second is that updating the
* global hash here from dl() is not mutex protected and can
* lead to death.
*/
if (directives != EG(ini_directives)) {
directives = EG(ini_directives);
}
#endif
while (p->name) {
p->module_number = module_number;
if (zend_hash_add(registered_zend_ini_directives, p->name, p->name_length, p, sizeof(zend_ini_entry), (void **) &hashed_ini_entry)==FAILURE) {
if (zend_hash_add(directives, p->name, p->name_length, p, sizeof(zend_ini_entry), (void **) &hashed_ini_entry)==FAILURE) {
zend_unregister_ini_entries(module_number TSRMLS_CC);
return FAILURE;
}
@@ -283,9 +299,9 @@ ZEND_API double zend_ini_double(char *name, uint name_length, int orig)
if (zend_hash_find(EG(ini_directives), name, name_length, (void **) &ini_entry)==SUCCESS) {
if (orig && ini_entry->modified) {
return (double) (ini_entry->orig_value ? strtod(ini_entry->orig_value, NULL) : 0.0);
return (double) (ini_entry->orig_value ? zend_strtod(ini_entry->orig_value, NULL) : 0.0);
} else if (ini_entry->value) {
return (double) strtod(ini_entry->value, NULL);
return (double) zend_strtod(ini_entry->value, NULL);
}
}
@@ -471,7 +487,7 @@ ZEND_API ZEND_INI_MH(OnUpdateReal)
p = (double *) (base+(size_t) mh_arg1);
*p = strtod(new_value, NULL);
*p = zend_strtod(new_value, NULL);
return SUCCESS;
}
+1 -1
View File
@@ -192,7 +192,7 @@ END_EXTERN_C()
/* INI parsing engine */
typedef void (*zend_ini_parser_cb_t)(zval *arg1, zval *arg2, int callback_type, void *arg);
BEGIN_EXTERN_C()
int zend_parse_ini_file(zend_file_handle *fh, zend_bool unbuffered_errors, zend_ini_parser_cb_t ini_parser_cb, void *arg);
ZEND_API int zend_parse_ini_file(zend_file_handle *fh, zend_bool unbuffered_errors, zend_ini_parser_cb_t ini_parser_cb, void *arg);
END_EXTERN_C()
#define ZEND_INI_PARSER_ENTRY 1
+1 -1
View File
@@ -139,7 +139,7 @@ static void ini_error(char *str)
}
int zend_parse_ini_file(zend_file_handle *fh, zend_bool unbuffered_errors, zend_ini_parser_cb_t ini_parser_cb, void *arg)
ZEND_API int zend_parse_ini_file(zend_file_handle *fh, zend_bool unbuffered_errors, zend_ini_parser_cb_t ini_parser_cb, void *arg)
{
int retval;
zend_ini_parser_param ini_parser_param;
+2 -2
View File
@@ -272,7 +272,7 @@ static zend_object_iterator *zend_user_it_get_new_iterator(zend_class_entry *ce,
zend_class_entry *ce_it = Z_TYPE_P(iterator) == IS_OBJECT ? Z_OBJCE_P(iterator) : NULL;
if (!ce || !ce_it || !ce_it->get_iterator) {
if (!ce || !ce_it || !ce_it->get_iterator || (ce_it->get_iterator == zend_user_it_get_new_iterator && iterator == object)) {
zend_error(E_WARNING, "Objects returned by %s::getIterator() must be traversable or implement interface Iterator", ce->name);
zval_ptr_dtor(&iterator);
return NULL;
@@ -287,7 +287,7 @@ static zend_object_iterator *zend_user_it_get_new_iterator(zend_class_entry *ce,
static int zend_implement_traversable(zend_class_entry *interface, zend_class_entry *class_type TSRMLS_DC)
{
/* check that class_type is traversable at c-level or implements at least one of 'aggregate' and 'Iterator' */
int i;
zend_uint i;
if (class_type->get_iterator || (class_type->parent && class_type->parent->get_iterator)) {
return SUCCESS;
+4 -4
View File
@@ -614,12 +614,12 @@ function_call:
T_STRING '(' { $2.u.opline_num = zend_do_begin_function_call(&$1 TSRMLS_CC); }
function_call_parameter_list
')' { zend_do_end_function_call(&$1, &$$, &$4, 0, $2.u.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); }
| class_constant '(' { zend_do_begin_class_member_function_call(TSRMLS_C); zend_do_extended_fcall_begin(TSRMLS_C); }
| fully_qualified_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING '(' { zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); }
function_call_parameter_list
')' { zend_do_end_function_call(NULL, &$$, &$4, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
| static_member '(' { zend_do_end_variable_parse(BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(TSRMLS_C); zend_do_extended_fcall_begin(TSRMLS_C); }
')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
| fully_qualified_class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects '(' { zend_do_end_variable_parse(BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); }
function_call_parameter_list
')' { zend_do_end_function_call(NULL, &$$, &$4, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
| variable_without_objects '(' { zend_do_end_variable_parse(BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_dynamic_function_call(&$1 TSRMLS_CC); }
function_call_parameter_list ')'
{ zend_do_end_function_call(&$1, &$$, &$4, 0, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);}
+4 -3
View File
@@ -57,6 +57,7 @@
#include "zend_constants.h"
#include "zend_variables.h"
#include "zend_operators.h"
#include "zend_strtod.h"
#ifdef HAVE_STDARG_H
# include <stdarg.h>
@@ -1188,7 +1189,7 @@ NEWLINE ("\r"|"\n"|"\r\n")
errno = 0;
zendlval->value.lval = strtol(yytext, NULL, 0);
if (errno == ERANGE) { /* overflow */
zendlval->value.dval = strtod(yytext, NULL);
zendlval->value.dval = zend_strtod(yytext, NULL);
zendlval->type = IS_DOUBLE;
return T_DNUMBER;
} else {
@@ -1225,7 +1226,7 @@ NEWLINE ("\r"|"\n"|"\r\n")
}
<ST_IN_SCRIPTING>{DNUM}|{EXPONENT_DNUM} {
zendlval->value.dval = strtod(yytext, NULL);
zendlval->value.dval = zend_strtod(yytext, NULL);
zendlval->type = IS_DOUBLE;
return T_DNUMBER;
}
@@ -1445,7 +1446,7 @@ NEWLINE ("\r"|"\n"|"\r\n")
}
}
<ST_IN_SCRIPTING>"/**"{NEWLINE} {
<ST_IN_SCRIPTING>"/**"{WHITESPACE} {
CG(comment_start_line) = CG(zend_lineno);
BEGIN(ST_DOC_COMMENT);
yymore();
+8 -2
View File
@@ -24,10 +24,16 @@
#include <sys/types.h>
#include "zend.h"
#include "zend_types.h"
/* Define this to enable Zend MM */
#define ZEND_MM
#ifdef ZEND_WIN32
#undef ZEND_MM
#else
/* #define ZEND_MM */
#undef ZEND_MM
#endif
/* mm block type */
typedef struct _zend_mm_block {
+1 -1
View File
@@ -37,7 +37,7 @@ extern struct _zend_arg_info third_arg_force_ref[4];
extern struct _zend_arg_info fourth_arg_force_ref[5];
extern struct _zend_arg_info all_args_by_ref[1];
#define ZEND_MODULE_API_NO 20040412
#define ZEND_MODULE_API_NO 20041030
#ifdef ZTS
#define USING_ZTS 1
#else
+7
View File
@@ -381,7 +381,14 @@ zval *zend_std_read_dimension(zval *object, zval *offset, int type TSRMLS_DC)
zval *retval;
if (instanceof_function_ex(ce, zend_ce_arrayaccess, 1 TSRMLS_CC)) {
if(offset == NULL) {
/* [] construct */
zval offset_null;
INIT_ZVAL(offset_null);
offset = &offset_null;
}
zend_call_method_with_1_params(&object, ce, NULL, "offsetget", &retval, offset);
if (!retval) {
if (!EG(exception)) {
zend_error(E_ERROR, "Undefined offset for object of type %s used as array", ce->name);
+6 -3
View File
@@ -76,10 +76,13 @@ ZEND_API void zend_objects_destroy_object(zend_object *object, zend_object_handl
old_exception = EG(exception);
EG(exception) = NULL;
zend_call_method_with_0_params(&obj, object->ce, NULL, "__destruct", NULL);
if (EG(exception)) {
zval_ptr_dtor(&EG(exception));
if (old_exception) {
if (EG(exception)) {
zend_error(E_ERROR, "Ignoring exception from %s::__destruct() while an exception is already active", object->ce->name);
zval_ptr_dtor(&EG(exception));
}
EG(exception) = old_exception;
}
EG(exception) = old_exception;
}
}
+19
View File
@@ -58,6 +58,16 @@ ZEND_API void zend_objects_store_call_destructors(zend_objects_store *objects TS
}
}
ZEND_API void zend_objects_store_mark_destructed(zend_objects_store *objects TSRMLS_DC)
{
zend_uint i = 1;
for (i = 1; i < objects->top ; i++) {
if (objects->object_buckets[i].valid) {
objects->object_buckets[i].destructor_called = 1;
}
}
}
ZEND_API void zend_objects_store_free_object_storage(zend_objects_store *objects TSRMLS_DC)
{
@@ -207,6 +217,15 @@ ZEND_API void zend_object_store_set_object(zval *zobject, void *object TSRMLS_DC
}
/* Called when the ctor was terminated by an exception */
ZEND_API void zend_object_store_ctor_failed(zval *zobject TSRMLS_DC)
{
zend_object_handle handle = Z_OBJ_HANDLE_P(zobject);
EG(objects_store).object_buckets[handle].destructor_called = 1;
}
/* Proxy objects workings */
typedef struct _zend_proxy_object {
zval *object;
+2
View File
@@ -57,6 +57,7 @@ typedef struct _zend_objects_store {
BEGIN_EXTERN_C()
ZEND_API void zend_objects_store_init(zend_objects_store *objects, zend_uint init_size);
ZEND_API void zend_objects_store_call_destructors(zend_objects_store *objects TSRMLS_DC);
ZEND_API void zend_objects_store_mark_destructed(zend_objects_store *objects TSRMLS_DC);
ZEND_API void zend_objects_store_destroy(zend_objects_store *objects);
/* Store API functions */
@@ -68,6 +69,7 @@ ZEND_API zend_object_value zend_objects_store_clone_obj(zval *object TSRMLS_DC);
ZEND_API void *zend_object_store_get_object(zval *object TSRMLS_DC);
/* See comment in zend_objects_API.c before you use this */
ZEND_API void zend_object_store_set_object(zval *zobject, void *object TSRMLS_DC);
ZEND_API void zend_object_store_ctor_failed(zval *zobject TSRMLS_DC);
ZEND_API void zend_objects_store_free_object_storage(zend_objects_store *objects TSRMLS_DC);
+7
View File
@@ -108,6 +108,13 @@ ZEND_API void destroy_zend_function(zend_function *function TSRMLS_DC)
}
}
ZEND_API void zend_function_dtor(zend_function *function)
{
TSRMLS_FETCH();
destroy_zend_function(function TSRMLS_CC);
}
static void zend_cleanup_op_array_data(zend_op_array *op_array)
{
if (op_array->static_variables) {
+39 -16
View File
@@ -29,6 +29,7 @@
#include "zend_fast_cache.h"
#include "zend_API.h"
#include "zend_multiply.h"
#include "zend_strtod.h"
#define LONG_SIGN_MASK (1L << (8*sizeof(long)-1))
@@ -376,7 +377,7 @@ ZEND_API void convert_to_double(zval *op)
case IS_STRING:
strval = op->value.str.val;
op->value.dval = strtod(strval, NULL);
op->value.dval = zend_strtod(strval, NULL);
STR_FREE(strval);
break;
case IS_ARRAY:
@@ -1221,6 +1222,35 @@ ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_D
return SUCCESS;
}
#if HAVE_STRCOLL
ZEND_API int string_locale_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
{
zval op1_copy, op2_copy;
int use_copy1, use_copy2;
zend_make_printable_zval(op1, &op1_copy, &use_copy1);
zend_make_printable_zval(op2, &op2_copy, &use_copy2);
if (use_copy1) {
op1 = &op1_copy;
}
if (use_copy2) {
op2 = &op2_copy;
}
result->value.lval = strcoll(op1->value.str.val, op2->value.str.val);
result->type = IS_LONG;
if (use_copy1) {
zval_dtor(op1);
}
if (use_copy2) {
zval_dtor(op2);
}
return SUCCESS;
}
#endif
ZEND_API int numeric_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
{
zval op1_copy, op2_copy;
@@ -1867,9 +1897,9 @@ ZEND_API void zendi_smart_strcmp(zval *result, zval *s1, zval *s2)
(ret2=is_numeric_string(s2->value.str.val, s2->value.str.len, &lval2, &dval2, 0))) {
if ((ret1==IS_DOUBLE) || (ret2==IS_DOUBLE)) {
if (ret1!=IS_DOUBLE) {
dval1 = strtod(s1->value.str.val, NULL);
dval1 = zend_strtod(s1->value.str.val, NULL);
} else if (ret2!=IS_DOUBLE) {
dval2 = strtod(s2->value.str.val, NULL);
dval2 = zend_strtod(s2->value.str.val, NULL);
}
result->value.dval = dval1 - dval2;
result->value.lval = ZEND_NORMALIZE_BOOL(result->value.dval);
@@ -1922,13 +1952,13 @@ ZEND_API void zend_compare_objects(zval *result, zval *o1, zval *o2 TSRMLS_DC)
{
result->type = IS_LONG;
if (Z_OBJ_HT_P(o1)->compare_objects == NULL) {
if (Z_OBJ_HANDLE_P(o1) == Z_OBJ_HANDLE_P(o2)) {
result->value.lval = 0;
} else {
result->value.lval = 1;
}
if (Z_OBJ_HANDLE_P(o1) == Z_OBJ_HANDLE_P(o2)) {
result->value.lval = 0;
return;
}
if (Z_OBJ_HT_P(o1)->compare_objects == NULL) {
result->value.lval = 1;
} else {
result->value.lval = Z_OBJ_HT_P(o1)->compare_objects(o1, o2 TSRMLS_CC);
}
@@ -1943,13 +1973,6 @@ ZEND_API void zend_locale_sprintf_double(zval *op ZEND_FILE_LINE_DC)
op->value.str.val = (char *) emalloc_rel(MAX_LENGTH_OF_DOUBLE + EG(precision) + 1);
sprintf(op->value.str.val, "%.*G", (int) EG(precision), dval);
op->value.str.len = strlen(op->value.str.val);
if (EG(float_separator)[0] != '.') {
char *p = op->value.str.val;
if ((p = strchr(p, '.'))) {
*p = EG(float_separator)[0];
}
}
}
/*
+7 -1
View File
@@ -29,6 +29,7 @@
#include <ieeefp.h>
#endif
#include "zend_strtod.h"
#if 0&&HAVE_BCMATH
#include "ext/bcmath/libbcmath/src/bcmath.h"
@@ -87,6 +88,8 @@ static inline zend_bool is_numeric_string(char *str, int length, long *lval, dou
*lval = local_lval;
}
return IS_LONG;
} else if (end_ptr_long == str && *end_ptr_long != '\0' && *str != '.') { /* ignore partial string matches */
return 0;
}
} else {
end_ptr_long=NULL;
@@ -97,7 +100,7 @@ static inline zend_bool is_numeric_string(char *str, int length, long *lval, dou
}
errno=0;
local_dval = strtod(str, &end_ptr_double);
local_dval = zend_strtod(str, &end_ptr_double);
if (errno != ERANGE) {
if (end_ptr_double == str+length) { /* floating point string */
if (!zend_finite(local_dval)) {
@@ -177,6 +180,9 @@ ZEND_API int zval_is_true(zval *op);
ZEND_API int compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
ZEND_API int numeric_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
#if HAVE_STRCOLL
ZEND_API int string_locale_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
#endif
ZEND_API void zend_str_tolower(char *str, unsigned int length);
ZEND_API char *zend_str_tolower_copy(char *dest, const char *source, unsigned int length);
+414 -183
View File
File diff suppressed because it is too large. Load diff
+4 -4
View File
@@ -49,7 +49,7 @@ ZEND_API int zend_stream_open(const char *filename, zend_file_handle *handle TSR
return (handle->handle.fp) ? SUCCESS : FAILURE;
}
int zend_stream_fixup(zend_file_handle *file_handle TSRMLS_DC)
ZEND_API int zend_stream_fixup(zend_file_handle *file_handle TSRMLS_DC)
{
switch (file_handle->type) {
case ZEND_HANDLE_FILENAME:
@@ -90,7 +90,7 @@ int zend_stream_fixup(zend_file_handle *file_handle TSRMLS_DC)
return SUCCESS;
}
size_t zend_stream_read(zend_file_handle *file_handle, char *buf, size_t len TSRMLS_DC)
ZEND_API size_t zend_stream_read(zend_file_handle *file_handle, char *buf, size_t len TSRMLS_DC)
{
if (file_handle->handle.stream.interactive) {
int c = '*', n;
@@ -105,7 +105,7 @@ size_t zend_stream_read(zend_file_handle *file_handle, char *buf, size_t len TSR
return file_handle->handle.stream.reader(file_handle->handle.stream.handle, buf, len TSRMLS_CC);
}
int zend_stream_getc(zend_file_handle *file_handle TSRMLS_DC)
ZEND_API int zend_stream_getc(zend_file_handle *file_handle TSRMLS_DC)
{
char buf;
@@ -115,7 +115,7 @@ int zend_stream_getc(zend_file_handle *file_handle TSRMLS_DC)
return EOF;
}
int zend_stream_ferror(zend_file_handle *file_handle TSRMLS_DC)
ZEND_API int zend_stream_ferror(zend_file_handle *file_handle TSRMLS_DC)
{
return 0;
}
+4 -4
View File
@@ -49,10 +49,10 @@ typedef struct _zend_file_handle {
BEGIN_EXTERN_C()
ZEND_API int zend_stream_open(const char *filename, zend_file_handle *handle TSRMLS_DC);
int zend_stream_ferror(zend_file_handle *file_handle TSRMLS_DC);
int zend_stream_getc(zend_file_handle *file_handle TSRMLS_DC);
size_t zend_stream_read(zend_file_handle *file_handle, char *buf, size_t len TSRMLS_DC);
int zend_stream_fixup(zend_file_handle *file_handle TSRMLS_DC);
ZEND_API int zend_stream_ferror(zend_file_handle *file_handle TSRMLS_DC);
ZEND_API int zend_stream_getc(zend_file_handle *file_handle TSRMLS_DC);
ZEND_API size_t zend_stream_read(zend_file_handle *file_handle, char *buf, size_t len TSRMLS_DC);
ZEND_API int zend_stream_fixup(zend_file_handle *file_handle TSRMLS_DC);
END_EXTERN_C()
#define zend_stream_close(handle) zend_file_handle_dtor((handle))
+1769
View File
File diff suppressed because it is too large. Load diff
+31
View File
@@ -0,0 +1,31 @@
/*
+----------------------------------------------------------------------+
| Zend Engine |
+----------------------------------------------------------------------+
| Copyright (c) 1998-2004 Zend Technologies Ltd. (http://www.zend.com) |
+----------------------------------------------------------------------+
| This source file is subject to version 2.00 of the Zend license, |
| that is bundled with this package in the file LICENSE, and is |
| available through the world-wide-web at the following url: |
| http://www.zend.com/license/2_00.txt. |
| If you did not receive a copy of the Zend license and are unable to |
| obtain it through the world-wide-web, please send a note to |
| license@zend.com so we can mail you a copy immediately. |
+----------------------------------------------------------------------+
| Authors: Derick Rethans <derick@php.net> |
+----------------------------------------------------------------------+
*/
/* $Id$ */
/* This is a header file for the strtod implementation by David M. Gay which
* can be found in zend_strtod.c */
#ifndef ZEND_STRTOD_H
#define ZEND_STRTOD_H
#include <zend.h>
BEGIN_EXTERN_C()
ZEND_API double zend_strtod(const char *s00, char **se);
END_EXTERN_C()
#endif
+5 -3
View File
@@ -140,14 +140,16 @@ ZEND_API int _zval_copy_ctor(zval *zvalue ZEND_FILE_LINE_DC)
case IS_CONSTANT_ARRAY: {
zval *tmp;
HashTable *original_ht = zvalue->value.ht;
HashTable *tmp_ht = NULL;
TSRMLS_FETCH();
if (zvalue->value.ht == &EG(symbol_table)) {
return SUCCESS; /* do nothing */
}
ALLOC_HASHTABLE_REL(zvalue->value.ht);
zend_hash_init(zvalue->value.ht, 0, NULL, ZVAL_PTR_DTOR, 0);
zend_hash_copy(zvalue->value.ht, original_ht, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
ALLOC_HASHTABLE_REL(tmp_ht);
zend_hash_init(tmp_ht, 0, NULL, ZVAL_PTR_DTOR, 0);
zend_hash_copy(tmp_ht, original_ht, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
zvalue->value.ht = tmp_ht;
}
break;
case IS_OBJECT:
+15 -7
View File
@@ -1,4 +1,4 @@
dnl $Id$
dnl $Id$ -*- autoconf -*-
dnl
dnl This file contains local autoconf functions.
@@ -21,12 +21,12 @@ AC_DEFUN(PHP_PROG_RE2C,[
])
dnl PHP_DEFINE(WHAT[, value])
dnl PHP_DEFINE(WHAT[, value[, directory]])
dnl
dnl Creates builddir/include/what.h and in there #define WHAT value
dnl
AC_DEFUN([PHP_DEFINE],[
[echo "#define ]$1[]ifelse([$2],,[ 1],[ $2])[" > include/php_]translit($1,A-Z,a-z)[.h]
[echo "#define ]$1[]ifelse([$2],,[ 1],[ $2])[" > ]ifelse([$3],,[include],[$3])[/php_]translit($1,A-Z,a-z)[.h]
])
dnl PHP_INIT_BUILD_SYSTEM
@@ -1695,16 +1695,24 @@ AC_DEFUN([PHP_SETUP_ICONV], [
found_iconv=no
unset ICONV_DIR
# Create the directories for a VPATH build:
test -d ext || mkdir ext
test -d ext/iconv || mkdir ext/iconv
echo > ext/iconv/php_have_libiconv.h
echo > ext/iconv/php_have_iconv.h
echo > ext/iconv/php_php_iconv_impl.h
dnl
dnl Check libc first if no path is provided in --with-iconv
dnl
if test "$PHP_ICONV" = "yes"; then
AC_CHECK_FUNC(iconv, [
PHP_DEFINE(HAVE_ICONV)
PHP_DEFINE(HAVE_ICONV,1,[ext/iconv])
found_iconv=yes
],[
AC_CHECK_FUNC(libiconv,[
PHP_DEFINE(HAVE_LIBICONV)
PHP_DEFINE(HAVE_LIBICONV,1,[ext/iconv])
found_iconv=yes
])
])
@@ -1737,11 +1745,11 @@ AC_DEFUN([PHP_SETUP_ICONV], [
then
PHP_CHECK_LIBRARY($iconv_lib_name, libiconv, [
found_iconv=yes
PHP_DEFINE(HAVE_LIBICONV)
PHP_DEFINE(HAVE_LIBICONV,1,[ext/iconv])
], [
PHP_CHECK_LIBRARY($iconv_lib_name, iconv, [
found_iconv=yes
PHP_DEFINE(HAVE_ICONV)
PHP_DEFINE(HAVE_ICONV,1,[ext/iconv])
], [], [
-L$ICONV_DIR/lib
])
+24 -8
View File
@@ -40,8 +40,8 @@ AC_CONFIG_HEADER(main/php_config.h)
MAJOR_VERSION=5
MINOR_VERSION=0
RELEASE_VERSION=0
EXTRA_VERSION="RC3RC1"
RELEASE_VERSION=3
EXTRA_VERSION="RC2"
VERSION="$MAJOR_VERSION.$MINOR_VERSION.$RELEASE_VERSION$EXTRA_VERSION"
dnl Define where extension directories are located in the configure context
@@ -545,17 +545,20 @@ AC_CACHE_CHECK([for getaddrinfo], ac_cv_func_getaddrinfo,
AC_TRY_RUN([
#include <netdb.h>
#include <sys/types.h>
#ifndef AF_INET
# include <sys/socket.h>
#endif
int main(void) {
struct addrinfo *ai, *pai, hints;
memset(&hints, 0, sizeof(hints));
hints.ai_flags = AI_NUMERICHOST;
if (getaddrinfo("127.0.0.1", NULL, &hints, &ai) < 0) {
if (getaddrinfo("127.0.0.1", 0, &hints, &ai) < 0) {
exit(1);
}
if (ai == NULL) {
if (ai == 0) {
exit(1);
}
@@ -584,8 +587,8 @@ fi
AC_REPLACE_FUNCS(strlcat strlcpy getopt)
AC_FUNC_UTIME_NULL
AC_FUNC_ALLOCA
PHP_AC_BROKEN_SPRINTF
PHP_AC_BROKEN_SNPRINTF
dnl PHP_AC_BROKEN_SPRINTF
dnl PHP_AC_BROKEN_SNPRINTF
PHP_DECLARED_TIMEZONE
PHP_TIME_R_TYPE
PHP_READDIR_R_TYPE
@@ -765,6 +768,19 @@ if test "$PHP_IPV6" != "no" && test "$ac_cv_ipv6_support" = yes; then
AC_DEFINE(HAVE_IPV6,1,[Whether to enable IPv6 support])
fi
AC_MSG_CHECKING([how big to make fd sets])
AC_ARG_ENABLE(fd-setsize,
[ --enable-fd-setsize Set size of descriptor sets],[
if test "x$enableval" != "xyes"; then
CPPFLAGS="$CPPFLAGS -DFD_SETSIZE=$enableval"
AC_MSG_RESULT(using $enableval)
else
AC_MSG_RESULT(using system default)
fi
],[
AC_MSG_RESULT(using system default)
])
AC_MSG_CHECKING([whether to enable versioning])
AC_ARG_ENABLE(versioning,
[ --enable-versioning Export only required symbols.
@@ -933,7 +949,7 @@ fi
if test "$abs_srcdir" != "$abs_builddir"; then
INCLUDES="$INCLUDES -I\$(top_srcdir)/main -I\$(top_srcdir)/Zend"
INCLUDES="$INCLUDES -I\$(top_srcdir)/TSRM"
INCLUDES="$INCLUDES -I\$(top_srcdir)/TSRM -I\$(top_builddir)/"
fi
ZEND_EXTRA_LIBS="$LIBS"
@@ -1232,7 +1248,7 @@ PHP_ADD_SOURCES(Zend, \
zend_variables.c zend.c zend_API.c zend_extensions.c zend_hash.c \
zend_list.c zend_indent.c zend_builtin_functions.c zend_sprintf.c \
zend_ini.c zend_qsort.c zend_multibyte.c zend_ts_hash.c zend_stream.c \
zend_iterators.c zend_interfaces.c zend_exceptions.c)
zend_iterators.c zend_interfaces.c zend_exceptions.c zend_strtod.c)
if test -r "$abs_srcdir/Zend/zend_objects.c"; then
PHP_ADD_SOURCES(Zend, zend_objects.c zend_object_handlers.c zend_objects_API.c zend_mm.c \
+24 -8
View File
@@ -53,8 +53,8 @@ zend_module_entry bcmath_module_entry = {
bcmath_functions,
PHP_MINIT(bcmath),
PHP_MSHUTDOWN(bcmath),
NULL,
NULL,
PHP_RINIT(bcmath),
PHP_RSHUTDOWN(bcmath),
PHP_MINFO(bcmath),
NO_VERSION_YET,
STANDARD_MODULE_PROPERTIES
@@ -86,8 +86,6 @@ PHP_MINIT_FUNCTION(bcmath)
REGISTER_INI_ENTRIES();
bc_init_numbers(TSRMLS_C);
return SUCCESS;
}
/* }}} */
@@ -96,15 +94,33 @@ PHP_MINIT_FUNCTION(bcmath)
*/
PHP_MSHUTDOWN_FUNCTION(bcmath)
{
_bc_free_num_ex(&BCG(_zero_), 1);
_bc_free_num_ex(&BCG(_one_), 1);
_bc_free_num_ex(&BCG(_two_), 1);
UNREGISTER_INI_ENTRIES();
return SUCCESS;
}
/* }}} */
/* {{{ PHP_RINIT_FUNCTION
*/
PHP_RINIT_FUNCTION(bcmath)
{
bc_init_numbers(TSRMLS_C);
return SUCCESS;
}
/* }}} */
/* {{{ PHP_RSHUTDOWN_FUNCTION
*/
PHP_RSHUTDOWN_FUNCTION(bcmath)
{
_bc_free_num_ex(&BCG(_zero_), 1);
_bc_free_num_ex(&BCG(_one_), 1);
_bc_free_num_ex(&BCG(_two_), 1);
return SUCCESS;
}
/* }}} */
/* {{{ PHP_MINFO_FUNCTION
*/
+1
View File
@@ -92,6 +92,7 @@ bc_raisemod (bc_num base, bc_num expo, bc_num mod, bc_num *result, int scale TSR
bc_free_num (&power);
bc_free_num (&exponent);
bc_free_num (result);
bc_free_num (&parity);
*result = temp;
return 0; /* Everything is OK. */
}
+2
View File
@@ -30,6 +30,8 @@ extern zend_module_entry bcmath_module_entry;
PHP_MINIT_FUNCTION(bcmath);
PHP_MSHUTDOWN_FUNCTION(bcmath);
PHP_RINIT_FUNCTION(bcmath);
PHP_RSHUTDOWN_FUNCTION(bcmath);
PHP_MINFO_FUNCTION(bcmath);
PHP_FUNCTION(bcadd);
+42 -19
View File
@@ -163,26 +163,14 @@ PHP_MINFO_FUNCTION(calendar)
php_info_print_table_end();
}
/* {{{ proto array cal_info(int calendar)
Returns information about a particular calendar */
PHP_FUNCTION(cal_info)
static void _php_cal_info(int cal, zval **ret)
{
long cal;
zval *months, *smonths;
int i;
struct cal_entry_t *calendar;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &cal) == FAILURE) {
RETURN_FALSE;
}
if (cal < 0 || cal >= CAL_NUM_CALS) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "invalid calendar ID %ld.", cal);
RETURN_FALSE;
}
calendar = &cal_conversion_table[cal];
array_init(return_value);
array_init(*ret);
MAKE_STD_ZVAL(months);
MAKE_STD_ZVAL(smonths);
@@ -193,11 +181,46 @@ PHP_FUNCTION(cal_info)
add_index_string(months, i, calendar->month_name_long[i], 1);
add_index_string(smonths, i, calendar->month_name_short[i], 1);
}
add_assoc_zval(return_value, "months", months);
add_assoc_zval(return_value, "abbrevmonths", smonths);
add_assoc_long(return_value, "maxdaysinmonth", calendar->max_days_in_month);
add_assoc_string(return_value, "calname", calendar->name, 1);
add_assoc_string(return_value, "calsymbol", calendar->symbol, 1);
add_assoc_zval(*ret, "months", months);
add_assoc_zval(*ret, "abbrevmonths", smonths);
add_assoc_long(*ret, "maxdaysinmonth", calendar->max_days_in_month);
add_assoc_string(*ret, "calname", calendar->name, 1);
add_assoc_string(*ret, "calsymbol", calendar->symbol, 1);
}
/* {{{ proto array cal_info(int calendar)
Returns information about a particular calendar */
PHP_FUNCTION(cal_info)
{
long cal = -1;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &cal) == FAILURE) {
RETURN_FALSE;
}
if (cal == -1) {
int i;
zval *val;
array_init(return_value);
for (i = 0; i < CAL_NUM_CALS; i++) {
MAKE_STD_ZVAL(val);
_php_cal_info(i, &val);
add_index_zval(return_value, i, val);
}
return;
}
if (cal != -1 && (cal < 0 || cal >= CAL_NUM_CALS)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "invalid calendar ID %ld.", cal);
RETURN_FALSE;
}
_php_cal_info(cal, &return_value);
}
/* }}} */
+3 -3
View File
@@ -37,7 +37,7 @@ PHP_FUNCTION(com_create_instance)
php_com_dotnet_object *obj;
char *module_name, *typelib_name = NULL, *server_name = NULL;
char *user_name = NULL, *domain_name = NULL, *password = NULL;
long module_name_len, typelib_name_len, server_name_len,
int module_name_len, typelib_name_len, server_name_len,
user_name_len, domain_name_len, password_len;
OLECHAR *moniker;
CLSID clsid;
@@ -287,7 +287,7 @@ PHP_FUNCTION(com_get_active_object)
{
CLSID clsid;
char *module_name;
long module_name_len;
int module_name_len;
long code_page = COMG(code_page);
IUnknown *unk = NULL;
IDispatch *obj = NULL;
@@ -799,7 +799,7 @@ PHP_FUNCTION(com_message_pump)
PHP_FUNCTION(com_load_typelib)
{
char *name;
long namelen;
int namelen;
ITypeLib *pTL = NULL;
zend_bool cs = TRUE;
int codepage = COMG(code_page);
+174 -68
View File
@@ -32,53 +32,139 @@
# include "Zend/zend_exceptions.h"
# include <mscoree.h>
/* Since there is no official public mscorlib.h header file, and since
* generating your own version from the elusive binary .tlb file takes a lot of
* hacking and results in a 3MB header file (!), we opt for this slightly
* voodoo approach. The following is just enough definition to be able to
* reach the _AppDomain::CreateInstance method that we need to use to be able
* to fire up .Net objects. We used to use IDispatch for this, but it would
* not always work.
*
* The following info was obtained using OleView to export the IDL from
* mscorlib.tlb. Note that OleView is unable to generate C headers for this
* particular tlb... hence this mess.
*/
const GUID IID_mscorlib_System_AppDomain = {
0x05F696DC, 0x2B29, 0x3663, {0xAD, 0x8B, 0xC4, 0x38, 0x9C, 0xF2, 0xA7, 0x13 }};
typedef struct _Imscorlib_System_AppDomain IAppDomain;
struct _Imscorlib_System_AppDomainVtbl {
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IAppDomain * This,
/* [in] */ REFIID riid,
/* [iid_is][out] */ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
IAppDomain * This);
ULONG ( STDMETHODCALLTYPE *Release )(
IAppDomain * This);
/* this is padding to get CreateInstance into the correct position */
#define DUMMY_METHOD(x) HRESULT ( STDMETHODCALLTYPE *dummy_##x )(IAppDomain *This)
DUMMY_METHOD(GetTypeInfoCount);
DUMMY_METHOD(GetTypeInfo);
DUMMY_METHOD(GetIDsOfNames);
DUMMY_METHOD(Invoke);
DUMMY_METHOD(ToString);
DUMMY_METHOD(Equals);
DUMMY_METHOD(GetHashCode);
DUMMY_METHOD(GetType);
DUMMY_METHOD(InitializeLifetimeService);
DUMMY_METHOD(GetLifetimeService);
DUMMY_METHOD(Evidence);
DUMMY_METHOD(add_DomainUnload);
DUMMY_METHOD(remove_DomainUnload);
DUMMY_METHOD(add_AssemblyLoad);
DUMMY_METHOD(remove_AssemblyLoad);
DUMMY_METHOD(add_ProcessExit);
DUMMY_METHOD(remove_ProcessExit);
DUMMY_METHOD(add_TypeResolve);
DUMMY_METHOD(remove_TypeResolve);
DUMMY_METHOD(add_ResourceResolve);
DUMMY_METHOD(remove_ResourceResolve);
DUMMY_METHOD(add_AssemblyResolve);
DUMMY_METHOD(remove_AssemblyResolve);
DUMMY_METHOD(add_UnhandledException);
DUMMY_METHOD(remove_UnhandledException);
DUMMY_METHOD(DefineDynamicAssembly);
DUMMY_METHOD(DefineDynamicAssembly_2);
DUMMY_METHOD(DefineDynamicAssembly_3);
DUMMY_METHOD(DefineDynamicAssembly_4);
DUMMY_METHOD(DefineDynamicAssembly_5);
DUMMY_METHOD(DefineDynamicAssembly_6);
DUMMY_METHOD(DefineDynamicAssembly_7);
DUMMY_METHOD(DefineDynamicAssembly_8);
DUMMY_METHOD(DefineDynamicAssembly_9);
HRESULT ( STDMETHODCALLTYPE *CreateInstance )(IAppDomain * This, BSTR AssemblyName, BSTR typeName, IUnknown **pRetVal);
HRESULT ( STDMETHODCALLTYPE *CreateInstanceFrom )(IAppDomain * This, BSTR AssemblyFile, BSTR typeName, IUnknown **pRetVal);
/* more methods live here */
END_INTERFACE
};
struct _Imscorlib_System_AppDomain {
struct _Imscorlib_System_AppDomainVtbl *lpVtbl;
};
struct dotnet_runtime_stuff {
ICorRuntimeHost *dotnet_host;
IDispatch *dotnet_domain;
IAppDomain *dotnet_domain;
DISPID create_instance;
};
/* Since there is no official public mscorlib.h header file, and since
* generating your own version from the binary .tlb file results in a 3MB
* header file (!), we opt for the Dispatch-able approach. This is slightly
* slower for creating new objects, but not too bad */
static int dotnet_init(TSRMLS_D)
static HRESULT dotnet_init(char **p_where TSRMLS_DC)
{
HRESULT hr;
struct dotnet_runtime_stuff *stuff;
IUnknown *unk = NULL;
OLECHAR *olename;
OLECHAR *olename, *oletmp;
char *where = "";
stuff = malloc(sizeof(*stuff));
memset(stuff, 0, sizeof(*stuff));
if (SUCCEEDED(CoCreateInstance(&CLSID_CorRuntimeHost, NULL, CLSCTX_ALL,
&IID_ICorRuntimeHost, (LPVOID*)&stuff->dotnet_host))) {
where = "CoCreateInstance";
hr = CoCreateInstance(&CLSID_CorRuntimeHost, NULL, CLSCTX_ALL,
&IID_ICorRuntimeHost, (LPVOID*)&stuff->dotnet_host);
/* fire up the host and get the domain object */
if (SUCCEEDED(ICorRuntimeHost_Start(stuff->dotnet_host)) &&
SUCCEEDED(ICorRuntimeHost_GetDefaultDomain(stuff->dotnet_host, &unk)) &&
SUCCEEDED(IUnknown_QueryInterface(unk, &IID_IDispatch, (LPVOID*)&stuff->dotnet_domain))) {
if (FAILED(hr))
goto out;
/* locate the create-instance member */
olename = php_com_string_to_olestring("CreateInstance", sizeof("CreateInstance")-1, CP_ACP TSRMLS_CC);
hr = IDispatch_GetIDsOfNames(stuff->dotnet_domain, &IID_NULL, &olename, 1, LOCALE_SYSTEM_DEFAULT, &stuff->create_instance);
efree(olename);
/* fire up the host and get the domain object */
where = "ICorRuntimeHost_Start\n";
hr = ICorRuntimeHost_Start(stuff->dotnet_host);
if (FAILED(hr))
goto out;
where = "ICorRuntimeHost_GetDefaultDomain";
hr = ICorRuntimeHost_GetDefaultDomain(stuff->dotnet_host, &unk);
if (FAILED(hr))
goto out;
if (SUCCEEDED(hr)) {
COMG(dotnet_runtime_stuff) = stuff;
}
}
where = "QI: System._AppDomain";
hr = IUnknown_QueryInterface(unk, &IID_mscorlib_System_AppDomain, (LPVOID*)&stuff->dotnet_domain);
if (FAILED(hr))
goto out;
COMG(dotnet_runtime_stuff) = stuff;
if (unk) {
IUnknown_Release(unk);
}
out:
if (unk) {
IUnknown_Release(unk);
}
if (COMG(dotnet_runtime_stuff) == NULL) {
/* clean up */
if (stuff->dotnet_domain) {
IDispatch_Release(stuff->dotnet_domain);
IUnknown_Release(stuff->dotnet_domain);
}
if (stuff->dotnet_host) {
ICorRuntimeHost_Stop(stuff->dotnet_host);
@@ -86,10 +172,12 @@ static int dotnet_init(TSRMLS_D)
}
free(stuff);
return FAILURE;
*p_where = where;
return hr;
}
return SUCCESS;
return S_OK;
}
/* {{{ com_dotnet_create_instance - ctor for DOTNET class */
@@ -98,18 +186,23 @@ PHP_FUNCTION(com_dotnet_create_instance)
zval *object = getThis();
php_com_dotnet_object *obj;
char *assembly_name, *datatype_name;
long assembly_name_len, datatype_name_len;
int assembly_name_len, datatype_name_len;
struct dotnet_runtime_stuff *stuff;
IObjectHandle *handle;
DISPPARAMS params;
VARIANT vargs[2];
VARIANT retval;
OLECHAR *olestring, *oleassembly, *oletype;
HRESULT hr;
int ret = FAILURE;
char *where = "";
IUnknown *unk = NULL;
if (COMG(dotnet_runtime_stuff) == NULL) {
if (FAILURE == dotnet_init(TSRMLS_C)) {
php_com_throw_exception(E_ERROR, "Failed to initialize .Net runtime" TSRMLS_CC);
hr = dotnet_init(&where TSRMLS_CC);
if (FAILED(hr)) {
char buf[1024];
char *err = php_win_err(hr);
snprintf(buf, sizeof(buf), "Failed to init .Net runtime [%s] %s", where, err);
if (err)
LocalFree(err);
php_com_throw_exception(hr, buf TSRMLS_CC);
ZVAL_NULL(object);
return;
}
@@ -128,50 +221,63 @@ PHP_FUNCTION(com_dotnet_create_instance)
return;
}
params.cArgs = 2;
params.cNamedArgs = 0;
params.rgdispidNamedArgs = NULL;
params.rgvarg = vargs;
VariantInit(&vargs[0]);
VariantInit(&vargs[1]);
VariantInit(&retval);
V_VT(&vargs[0]) = VT_BSTR;
V_BSTR(&vargs[0]) = php_com_string_to_olestring(datatype_name, datatype_name_len, obj->code_page TSRMLS_CC);
V_VT(&vargs[1]) = VT_BSTR;
V_BSTR(&vargs[1]) = php_com_string_to_olestring(assembly_name, assembly_name_len, obj->code_page TSRMLS_CC);
hr = IDispatch_Invoke(stuff->dotnet_domain, stuff->create_instance, &IID_NULL, LOCALE_SYSTEM_DEFAULT,
DISPATCH_METHOD, &params, &retval, NULL, NULL);
oletype = php_com_string_to_olestring(datatype_name, datatype_name_len, obj->code_page TSRMLS_CC);
oleassembly = php_com_string_to_olestring(assembly_name, assembly_name_len, obj->code_page TSRMLS_CC);
where = "CreateInstance";
hr = stuff->dotnet_domain->lpVtbl->CreateInstance(stuff->dotnet_domain, oleassembly, oletype, &unk);
efree(oletype);
efree(oleassembly);
if (SUCCEEDED(hr)) {
/* retval should now be an IUnknown/IDispatch representation of an IObjectHandle interface */
if ((V_VT(&retval) == VT_UNKNOWN || V_VT(&retval) == VT_DISPATCH) &&
SUCCEEDED(IUnknown_QueryInterface(V_UNKNOWN(&retval), &IID_IObjectHandle, &handle))) {
VARIANT unwrapped;
VARIANT unwrapped;
IObjectHandle *handle = NULL;
if (SUCCEEDED(IObjectHandle_Unwrap(handle, &unwrapped))) {
/* unwrapped is now the dispatch pointer we want */
V_DISPATCH(&obj->v) = V_DISPATCH(&unwrapped);
V_VT(&obj->v) = VT_DISPATCH;
where = "QI: IObjectHandle";
hr = IUnknown_QueryInterface(unk, &IID_IObjectHandle, &handle);
/* get its type-info */
IDispatch_GetTypeInfo(V_DISPATCH(&obj->v), 0, LANG_NEUTRAL, &obj->typeinfo);
if (SUCCEEDED(hr)) {
where = "IObjectHandle_Unwrap";
hr = IObjectHandle_Unwrap(handle, &unwrapped);
if (SUCCEEDED(hr)) {
ret = SUCCESS;
if (V_VT(&unwrapped) == VT_UNKNOWN) {
where = "Unwrapped, QI for IDispatch";
hr = IUnknown_QueryInterface(V_UNKNOWN(&unwrapped), &IID_IDispatch, &V_DISPATCH(&obj->v));
if (SUCCEEDED(hr)) {
V_VT(&obj->v) = VT_DISPATCH;
/* get its type-info */
IDispatch_GetTypeInfo(V_DISPATCH(&obj->v), 0, LANG_NEUTRAL, &obj->typeinfo);
ret = SUCCESS;
}
} else if (V_VT(&unwrapped) == VT_DISPATCH) {
/* unwrapped is now the dispatch pointer we want */
V_DISPATCH(&obj->v) = V_DISPATCH(&unwrapped);
V_VT(&obj->v) = VT_DISPATCH;
/* get its type-info */
IDispatch_GetTypeInfo(V_DISPATCH(&obj->v), 0, LANG_NEUTRAL, &obj->typeinfo);
ret = SUCCESS;
} else {
/* shouldn't happen, but let's be ready for it */
VariantClear(&unwrapped);
hr = E_INVALIDARG;
}
}
IObjectHandle_Release(handle);
}
VariantClear(&retval);
IUnknown_Release(unk);
}
VariantClear(&vargs[0]);
VariantClear(&vargs[1]);
if (ret == FAILURE) {
php_com_throw_exception(hr, "Failed to instantiate .Net object" TSRMLS_CC);
char buf[1024];
char *err = php_win_err(hr);
snprintf(buf, sizeof(buf), "Failed to instantiate .Net object [%s] [0x%08x] %s", where, hr, err);
if (err)
LocalFree(err);
php_com_throw_exception(hr, buf TSRMLS_CC);
ZVAL_NULL(object);
return;
}
+1 -1
View File
@@ -194,7 +194,7 @@ PHP_MINIT_FUNCTION(com_dotnet)
INIT_CLASS_ENTRY(ce, "com_exception", NULL);
php_com_exception_class_entry = zend_register_internal_class_ex(&ce, zend_exception_get_default(), NULL TSRMLS_CC);
php_com_exception_class_entry->ce_flags |= ZEND_ACC_FINAL;
php_com_exception_class_entry->constructor->common.fn_flags |= ZEND_ACC_PROTECTED;
// php_com_exception_class_entry->constructor->common.fn_flags |= ZEND_ACC_PROTECTED;
INIT_CLASS_ENTRY(ce, "com_safearray_proxy", NULL);
php_com_saproxy_class_entry = zend_register_internal_class(&ce TSRMLS_CC);
+35 -11
View File
@@ -286,11 +286,19 @@ static void function_dtor(void *pDest)
}
}
static PHP_FUNCTION(com_method_handler)
{
Z_OBJ_HANDLER_P(getThis(), call_method)(
((zend_internal_function*)EG(function_state_ptr)->function)->function_name,
INTERNAL_FUNCTION_PARAM_PASSTHRU);
}
static union _zend_function *com_method_get(zval *object, char *name, int len TSRMLS_DC)
{
zend_internal_function f, *fptr = NULL;
php_com_dotnet_object *obj;
union _zend_function *func;
DISPID dummy;
obj = CDNO_FETCH(object);
@@ -298,6 +306,10 @@ static union _zend_function *com_method_get(zval *object, char *name, int len TS
return NULL;
}
if (FAILED(php_com_get_id_of_name(obj, name, len, &dummy TSRMLS_CC))) {
return NULL;
}
/* check cache */
if (obj->method_cache == NULL || FAILURE == zend_hash_find(obj->method_cache, name, len, (void**)&fptr)) {
f.type = ZEND_OVERLOADED_FUNCTION;
@@ -306,7 +318,10 @@ static union _zend_function *com_method_get(zval *object, char *name, int len TS
f.scope = obj->ce;
f.fn_flags = 0;
f.function_name = estrndup(name, len);
f.handler = PHP_FN(com_method_handler);
fptr = &f;
if (obj->typeinfo) {
/* look for byref params */
ITypeComp *comp;
@@ -346,6 +361,9 @@ static union _zend_function *com_method_get(zval *object, char *name, int len TS
case DESCKIND_TYPECOMP:
ITypeComp_Release(bindptr.lptcomp);
break;
case DESCKIND_NONE:
break;
}
if (TI) {
ITypeInfo_Release(TI);
@@ -356,21 +374,27 @@ static union _zend_function *com_method_get(zval *object, char *name, int len TS
}
}
/* save this method in the cache */
if (!obj->method_cache) {
ALLOC_HASHTABLE(obj->method_cache);
zend_hash_init(obj->method_cache, 2, NULL, function_dtor, 0);
}
if (fptr) {
/* save this method in the cache */
if (!obj->method_cache) {
ALLOC_HASHTABLE(obj->method_cache);
zend_hash_init(obj->method_cache, 2, NULL, function_dtor, 0);
}
zend_hash_update(obj->method_cache, name, len, &f, sizeof(f), (void**)&fptr);
zend_hash_update(obj->method_cache, name, len, &f, sizeof(f), (void**)&fptr);
}
}
/* duplicate this into a new chunk of emalloc'd memory,
* since the engine will efree it */
func = emalloc(sizeof(*fptr));
memcpy(func, fptr, sizeof(*fptr));
if (fptr) {
/* duplicate this into a new chunk of emalloc'd memory,
* since the engine will efree it */
func = emalloc(sizeof(*fptr));
memcpy(func, fptr, sizeof(*fptr));
return func;
return func;
}
return NULL;
}
static int com_call_method(char *method, INTERNAL_FUNCTION_PARAMETERS)
+2 -2
View File
@@ -375,7 +375,7 @@ CPH_METHOD(SaveToFile)
{
HRESULT res;
char *filename, *fullpath = NULL;
long filename_len;
int filename_len;
zend_bool remember = TRUE;
OLECHAR *olefilename = NULL;
CPH_FETCH();
@@ -438,7 +438,7 @@ CPH_METHOD(LoadFromFile)
{
HRESULT res;
char *filename, *fullpath;
long filename_len;
int filename_len;
long flags = 0;
OLECHAR *olefilename;
CPH_FETCH();
+4 -4
View File
@@ -168,7 +168,7 @@ static zval *saproxy_read_dimension(zval *object, zval *offset, int type TSRMLS_
VariantInit(&v);
/* we can return a real value */
indices = do_alloca(dims * sizeof(LONG));
indices = emalloc(dims * sizeof(LONG));
/* copy indices from proxy */
for (i = 0; i < dims; i++) {
@@ -191,7 +191,7 @@ static zval *saproxy_read_dimension(zval *object, zval *offset, int type TSRMLS_
res = SafeArrayGetElement(sa, indices, &v.lVal);
}
free_alloca(indices);
efree(indices);
if (SUCCEEDED(res)) {
php_com_wrap_variant(return_value, &v, proxy->obj->code_page TSRMLS_CC);
@@ -244,7 +244,7 @@ static void saproxy_write_dimension(zval *object, zval *offset, zval *value TSRM
VARTYPE vt;
dims = SafeArrayGetDim(V_ARRAY(&proxy->obj->v));
indices = do_alloca(dims * sizeof(LONG));
indices = emalloc(dims * sizeof(LONG));
/* copy indices from proxy */
for (i = 0; i < dims; i++) {
convert_to_long(proxy->indices[i]);
@@ -272,7 +272,7 @@ static void saproxy_write_dimension(zval *object, zval *offset, zval *value TSRM
res = SafeArrayPutElement(V_ARRAY(&proxy->obj->v), indices, &v.lVal);
}
free_alloca(indices);
efree(indices);
VariantClear(&v);
if (FAILED(res)) {
+10 -9
View File
@@ -227,34 +227,35 @@ void php_com_typelibrary_dtor(void *pDest)
PHPAPI ITypeLib *php_com_load_typelib_via_cache(char *search_string,
int codepage, int *cached TSRMLS_DC)
{
ITypeLib **TL;
ITypeLib **TLp;
ITypeLib *TL;
char *name_dup;
int l;
l = strlen(search_string);
if (zend_ts_hash_find(&php_com_typelibraries, search_string, l+1,
(void**)&TL) == SUCCESS) {
(void**)&TLp) == SUCCESS) {
*cached = 1;
/* add a reference for the caller */
ITypeLib_AddRef(*TL);
return *TL;
ITypeLib_AddRef(*TLp);
return *TLp;
}
*cached = 0;
name_dup = estrndup(search_string, l);
*TL = php_com_load_typelib(name_dup, codepage TSRMLS_CC);
TL = php_com_load_typelib(name_dup, codepage TSRMLS_CC);
efree(name_dup);
if (*TL) {
if (TL) {
if (SUCCESS == zend_ts_hash_update(&php_com_typelibraries,
search_string, l+1, (void*)*TL, sizeof(ITypeLib*), NULL)) {
search_string, l+1, (void*)TL, sizeof(ITypeLib*), NULL)) {
/* add a reference for the hash table */
ITypeLib_AddRef(*TL);
ITypeLib_AddRef(TL);
}
}
return *TL;
return TL;
}
ITypeInfo *php_com_locate_typeinfo(char *typelibname, php_com_dotnet_object *obj, char *dispname, int sink TSRMLS_DC)
+9 -8
View File
@@ -260,7 +260,7 @@ PHPAPI int php_com_zval_from_variant(zval *z, VARIANT *v, int codepage TSRMLS_DC
/* {{{ com_variant_create_instance - ctor for new VARIANT() */
PHP_FUNCTION(com_variant_create_instance)
{
VARTYPE vt = VT_EMPTY;
/* VARTYPE == unsigned short */ long vt = VT_EMPTY;
long codepage = CP_ACP;
zval *object = getThis();
php_com_dotnet_object *obj;
@@ -290,7 +290,7 @@ PHP_FUNCTION(com_variant_create_instance)
if (ZEND_NUM_ARGS() >= 2) {
res = VariantChangeType(&obj->v, &obj->v, 0, vt);
res = VariantChangeType(&obj->v, &obj->v, 0, (VARTYPE)vt);
if (FAILED(res)) {
char *werr, *msg;
@@ -788,7 +788,7 @@ PHP_FUNCTION(variant_date_to_timestamp)
Returns a variant date representation of a unix timestamp */
PHP_FUNCTION(variant_date_from_timestamp)
{
int timestamp;
long timestamp;
SYSTEMTIME systime;
struct tm *tmv;
VARIANT res;
@@ -799,7 +799,8 @@ PHP_FUNCTION(variant_date_from_timestamp)
}
VariantInit(&res);
tmv = gmtime(&timestamp);
tzset();
tmv = localtime(&timestamp);
memset(&systime, 0, sizeof(systime));
systime.wDay = tmv->tm_mday;
@@ -841,7 +842,7 @@ PHP_FUNCTION(variant_set_type)
{
zval *zobj;
php_com_dotnet_object *obj;
VARTYPE vt;
/* VARTYPE == unsigned short */ long vt;
HRESULT res;
if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC,
@@ -850,7 +851,7 @@ PHP_FUNCTION(variant_set_type)
}
obj = CDNO_FETCH(zobj);
res = VariantChangeType(&obj->v, &obj->v, 0, vt);
res = VariantChangeType(&obj->v, &obj->v, 0, (VARTYPE)vt);
if (SUCCEEDED(res)) {
if (vt != VT_DISPATCH && obj->typeinfo) {
@@ -876,7 +877,7 @@ PHP_FUNCTION(variant_cast)
{
zval *zobj;
php_com_dotnet_object *obj;
VARTYPE vt;
/* VARTYPE == unsigned short */ long vt;
VARIANT vres;
HRESULT res;
@@ -887,7 +888,7 @@ PHP_FUNCTION(variant_cast)
obj = CDNO_FETCH(zobj);
VariantInit(&vres);
res = VariantChangeType(&vres, &obj->v, 0, vt);
res = VariantChangeType(&vres, &obj->v, 0, (VARTYPE)vt);
if (SUCCEEDED(res)) {
php_com_wrap_variant(return_value, &vres, obj->code_page TSRMLS_CC);
+9 -5
View File
@@ -296,12 +296,16 @@ static HRESULT STDMETHODCALLTYPE disp_invokeex(
} else if (wFlags & DISPATCH_PROPERTYPUT) {
zend_update_property(Z_OBJCE_P(disp->object), disp->object, Z_STRVAL_PP(name), Z_STRLEN_PP(name)+1, *params[0] TSRMLS_CC);
} else if (wFlags & DISPATCH_METHOD) {
if (SUCCESS == call_user_function_ex(EG(function_table), &disp->object, *name,
&retval, pdp->cArgs, params, 1, NULL TSRMLS_CC)) {
ret = S_OK;
} else {
zend_try {
if (SUCCESS == call_user_function_ex(EG(function_table), &disp->object, *name,
&retval, pdp->cArgs, params, 1, NULL TSRMLS_CC)) {
ret = S_OK;
} else {
ret = DISP_E_EXCEPTION;
}
} zend_catch {
ret = DISP_E_EXCEPTION;
}
} zend_end_try();
} else {
trace("Don't know how to handle this invocation %08x\n", wFlags);
}
+1 -1
View File
@@ -36,7 +36,7 @@ typedef struct _php_com_dotnet_object {
VARIANT v;
ITypeInfo *typeinfo;
int code_page;
long code_page;
unsigned int have_default_bind:1;
zend_class_entry *ce;
+5 -1
View File
@@ -726,7 +726,7 @@ PHP_FUNCTION(cpdf_set_font)
int id, type;
CPDFdoc *pdf;
if (ZEND_NUM_ARGS() != 4 || zend_get_parameters_ex(ht, 4, &arg1, &arg2, &arg3, &arg4) == FAILURE) {
if (ZEND_NUM_ARGS() != 4 || zend_get_parameters_ex(4, &arg1, &arg2, &arg3, &arg4) == FAILURE) {
WRONG_PARAM_COUNT;
}
@@ -1286,6 +1286,10 @@ PHP_FUNCTION(cpdf_setdash)
convert_to_long_ex(arg2);
convert_to_long_ex(arg3);
if (!pdf->currentMemStream) {
RETURN_FALSE;
}
snprintf(buffer, BUFFERLEN, "[%d %d] 0", (int) Z_LVAL_PP(arg2), (int) Z_LVAL_PP(arg3));
cpdf_setdash(pdf, buffer);
+7 -1
View File
@@ -97,7 +97,13 @@ PHP_MINFO_FUNCTION(ctype)
return; \
switch (Z_TYPE_P(c)) { \
case IS_LONG: \
RETURN_BOOL(iswhat(Z_LVAL_P(c))); \
if (Z_LVAL_P(c) <= 255 && Z_LVAL_P(c) >= 0) { \
RETURN_BOOL(iswhat(Z_LVAL_P(c))); \
} else if (Z_LVAL_P(c) >= -128 && Z_LVAL_P(c) < 0) { \
RETURN_BOOL(iswhat(Z_LVAL_P(c) + 256)); \
} \
SEPARATE_ZVAL(&c); \
convert_to_string(c); \
case IS_STRING: \
{ \
char *p; \
+32 -11
View File
@@ -220,6 +220,9 @@ PHP_MINIT_FUNCTION(curl)
REGISTER_CURL_CONSTANT(CURLOPT_UNRESTRICTED_AUTH);
REGISTER_CURL_CONSTANT(CURLOPT_FTP_USE_EPRT);
REGISTER_CURL_CONSTANT(CURLOPT_HTTP200ALIASES);
REGISTER_CURL_CONSTANT(CURL_TIMECOND_IFMODSINCE);
REGISTER_CURL_CONSTANT(CURL_TIMECOND_IFUNMODSINCE);
REGISTER_CURL_CONSTANT(CURL_TIMECOND_LASTMOD);
#if LIBCURL_VERSION_NUM > 0x070a05 /* CURLOPT_HTTPAUTH is available since curl 7.10.6 */
REGISTER_CURL_CONSTANT(CURLOPT_HTTPAUTH);
@@ -231,7 +234,11 @@ PHP_MINIT_FUNCTION(curl)
REGISTER_CURL_CONSTANT(CURLAUTH_ANY);
REGISTER_CURL_CONSTANT(CURLAUTH_ANYSAFE);
#endif
#if LIBCURL_VERSION_NUM > 0x070a06 /* CURLOPT_PROXYAUTH is available since curl 7.10.7 */
REGISTER_CURL_CONSTANT(CURLOPT_PROXYAUTH);
#endif
/* Constants effecting the way CURLOPT_CLOSEPOLICY works */
REGISTER_CURL_CONSTANT(CURLCLOSEPOLICY_LEAST_RECENTLY_USED);
REGISTER_CURL_CONSTANT(CURLCLOSEPOLICY_LEAST_TRAFFIC);
@@ -424,6 +431,7 @@ static size_t curl_write(char *data, size_t size, size_t nmemb, void *ctx)
PHPWRITE(data, length);
break;
case PHP_CURL_FILE:
fflush(t->fp);
return fwrite(data, size, nmemb, t->fp);
case PHP_CURL_RETURN:
smart_str_appendl(&t->buf, data, (int) length);
@@ -794,6 +802,7 @@ PHP_FUNCTION(curl_init)
curl_easy_setopt(ch->cp, CURLOPT_WRITEHEADER, (void *) ch);
curl_easy_setopt(ch->cp, CURLOPT_DNS_USE_GLOBAL_CACHE, 1);
curl_easy_setopt(ch->cp, CURLOPT_DNS_CACHE_TIMEOUT, 120);
curl_easy_setopt(ch->cp, CURLOPT_MAXREDIRS, 20); /* prevent infinite redirects */
#if defined(ZTS)
curl_easy_setopt(ch->cp, CURLOPT_NOSIGNAL, 1);
#endif
@@ -912,6 +921,9 @@ PHP_FUNCTION(curl_setopt)
case CURLOPT_FTP_USE_EPRT:
#if LIBCURL_VERSION_NUM > 0x070a05 /* CURLOPT_HTTPAUTH is available since curl 7.10.6 */
case CURLOPT_HTTPAUTH:
#endif
#if LIBCURL_VERSION_NUM > 0x070a06 /* CURLOPT_PROXYAUTH is available since curl 7.10.7 */
case CURLOPT_PROXYAUTH:
#endif
case CURLOPT_UNRESTRICTED_AUTH:
case CURLOPT_PORT:
@@ -1084,7 +1096,7 @@ PHP_FUNCTION(curl_setopt)
error = curl_formadd(&first, &last,
CURLFORM_COPYNAME, string_key,
CURLFORM_NAMELENGTH, string_key_len - 1,
(ZVAL_REFCOUNT(*zvalue) > 1 ? CURLFORM_PTRCONTENTS : CURLFORM_COPYCONTENTS), postval,
CURLFORM_COPYCONTENTS, postval,
CURLFORM_CONTENTSLENGTH, Z_STRLEN_PP(current),
CURLFORM_END);
}
@@ -1326,10 +1338,13 @@ PHP_FUNCTION(curl_getinfo)
switch (option) {
case CURLINFO_EFFECTIVE_URL:
case CURLINFO_CONTENT_TYPE: {
char *s_code;
char *s_code = NULL;
curl_easy_getinfo(ch->cp, option, &s_code);
RETURN_STRING(s_code, 1);
if (curl_easy_getinfo(ch->cp, option, &s_code) == CURLE_OK && s_code) {
RETURN_STRING(s_code, 1);
} else {
RETURN_FALSE;
}
break;
}
case CURLINFO_HTTP_CODE:
@@ -1338,10 +1353,13 @@ PHP_FUNCTION(curl_getinfo)
case CURLINFO_FILETIME:
case CURLINFO_SSL_VERIFYRESULT:
case CURLINFO_REDIRECT_COUNT: {
long code;
long code = 0;
curl_easy_getinfo(ch->cp, option, &code);
RETURN_LONG(code);
if (curl_easy_getinfo(ch->cp, option, &code) == CURLE_OK) {
RETURN_LONG(code);
} else {
RETURN_FALSE;
}
break;
}
case CURLINFO_TOTAL_TIME:
@@ -1356,10 +1374,13 @@ PHP_FUNCTION(curl_getinfo)
case CURLINFO_CONTENT_LENGTH_UPLOAD:
case CURLINFO_STARTTRANSFER_TIME:
case CURLINFO_REDIRECT_TIME: {
double code;
double code = 0.0;
curl_easy_getinfo(ch->cp, option, &code);
RETURN_DOUBLE(code);
if (curl_easy_getinfo(ch->cp, option, &code) == CURLE_OK) {
RETURN_DOUBLE(code);
} else {
RETURN_FALSE;
}
break;
}
}
+1 -1
View File
@@ -299,7 +299,7 @@ php_stream *php_curl_stream_opener(php_stream_wrapper *wrapper, char *filename,
curl_easy_setopt(curlstream->curl, CURLOPT_PROGRESSDATA, stream);
curl_easy_setopt(curlstream->curl, CURLOPT_NOPROGRESS, 0);
curl_easy_setopt(curlstream->curl, CURLOPT_USERAGENT, "PHP/" PHP_VERSION);
curl_easy_setopt(curlstream->curl, CURLOPT_USERAGENT, FG(user_agent) ? FG(user_agent) : "PHP/" PHP_VERSION);
/* TODO: read cookies and options from context */
+5 -2
View File
@@ -11,8 +11,11 @@ AC_DEFUN(PHP_DBA_STD_BEGIN,[
AC_DEFUN(PHP_TEMP_LDFLAGS,[
old_LDFLAGS=$LDFLAGS
LDFLAGS="$1 $LDFLAGS"
$2
old_LIBS=$LIBS
LIBS="$2 $LIBS"
$3
LDFLAGS=$old_LDFLAGS
LIBS=$old_LIBS
])
dnl Assign INCLUDE/LFLAGS from PREFIX
@@ -169,7 +172,7 @@ dnl parameters(version, library list, function)
AC_DEFUN(PHP_DBA_DB_CHECK,[
for LIB in $2; do
if test -f $THIS_PREFIX/lib/lib$LIB.a -o -f $THIS_PREFIX/lib/lib$LIB.$SHLIB_SUFFIX_NAME; then
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib -l$LIB,[
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib, -l$LIB,[
AC_TRY_LINK([
#include "$THIS_INCLUDE"
],[
+4 -4
View File
@@ -14,7 +14,7 @@ magic_quotes_runtime=1
require_once('test.inc');
echo "database handler: $handler\n";
// print md5 checksum of test.cdb which is generated by cdb_make program
var_dump(md5(implode('',file(dirname(__FILE__).'/test.cdb'))));
var_dump(md5_file(dirname(__FILE__).'/test.cdb'));
if (($db_make=dba_open($db_file, "n", $handler))!==FALSE) {
dba_insert("1", "1", $db_make);
dba_insert("2", "2", $db_make);
@@ -26,7 +26,7 @@ magic_quotes_runtime=1
// dba_replace cdb_make doesn't know replace
dba_close($db_make);
// write md5 checksum of generated database file
var_dump(md5(implode('',file($db_file))));
var_dump(md5_file($db_file));
// no need to test created database: this is done by dba_cdb_read.phpt
} else {
echo "Error creating database\n";
@@ -34,5 +34,5 @@ magic_quotes_runtime=1
?>
--EXPECT--
database handler: cdb_make
string(32) "723d19f39c1b15b3b455dd64323148d1"
string(32) "723d19f39c1b15b3b455dd64323148d1"
string(32) "12fc5ba2b9dcfef2480e5324eeb5f3e5"
string(32) "12fc5ba2b9dcfef2480e5324eeb5f3e5"
+9
View File
@@ -0,0 +1,9 @@
// $Id$
// vim:ft=javascript
ARG_ENABLE("dio", "Enable the direct I/O support", "no");
if (PHP_DIO != "no") {
EXTENSION("dio", "dio.c");
AC_DEFINE('HAVE_DIO', 1, 'dio support');
}
+54 -6
View File
@@ -27,9 +27,15 @@
#include <sys/stat.h>
#include <sys/types.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <fcntl.h>
#ifndef PHP_WIN32
#include <termios.h>
#endif
/* e.g. IRIX does not have CRTSCTS */
#ifndef CRTSCTS
@@ -45,14 +51,20 @@ static int le_fd;
function_entry dio_functions[] = {
PHP_FE(dio_open, NULL)
#ifndef PHP_WIN32
PHP_FE(dio_truncate, NULL)
#endif
PHP_FE(dio_stat, NULL)
PHP_FE(dio_seek, NULL)
#ifndef PHP_WIN32
PHP_FE(dio_fcntl, NULL)
#endif
PHP_FE(dio_read, NULL)
PHP_FE(dio_write, NULL)
PHP_FE(dio_close, NULL)
#ifndef PHP_WIN32
PHP_FE(dio_tcsetattr, NULL)
#endif
{NULL, NULL, NULL}
};
@@ -76,8 +88,10 @@ ZEND_GET_MODULE(dio)
static void _dio_close_fd(zend_rsrc_list_entry *rsrc TSRMLS_DC)
{
php_fd_t *f = (php_fd_t *) rsrc->ptr;
close(f->fd);
free(f);
if (f) {
close(f->fd);
free(f);
}
}
#define RDIOC(c) REGISTER_LONG_CONSTANT(#c, c, CONST_CS | CONST_PERSISTENT)
@@ -94,15 +108,22 @@ PHP_MINIT_FUNCTION(dio)
RDIOC(O_EXCL);
RDIOC(O_TRUNC);
RDIOC(O_APPEND);
#ifdef O_NONBLOCK
RDIOC(O_NONBLOCK);
#endif
#ifdef O_NDELAY
RDIOC(O_NDELAY);
#endif
#ifdef O_SYNC
RDIOC(O_SYNC);
#endif
#ifdef O_ASYNC
RDIOC(O_ASYNC);
#endif
#ifdef O_NOCTTY
RDIOC(O_NOCTTY);
#endif
#ifndef PHP_WIN32
RDIOC(S_IRWXU);
RDIOC(S_IRUSR);
RDIOC(S_IWUSR);
@@ -127,6 +148,7 @@ PHP_MINIT_FUNCTION(dio)
RDIOC(F_UNLCK);
RDIOC(F_RDLCK);
RDIOC(F_WRLCK);
#endif
return SUCCESS;
}
@@ -138,10 +160,13 @@ PHP_MINFO_FUNCTION(dio)
php_info_print_table_end();
}
static void new_php_fd(php_fd_t **f, int fd)
static int new_php_fd(php_fd_t **f, int fd)
{
*f = malloc(sizeof(php_fd_t));
if (!(*f = malloc(sizeof(php_fd_t)))) {
return 0;
}
(*f)->fd = fd;
return 1;
}
/* {{{ proto resource dio_open(string filename, int flags[, int mode])
@@ -174,7 +199,10 @@ PHP_FUNCTION(dio_open)
RETURN_FALSE;
}
new_php_fd(&f, fd);
if (!new_php_fd(&f, fd)) {
RETURN_FALSE;
}
ZEND_REGISTER_RESOURCE(return_value, f, le_fd);
}
/* }}} */
@@ -195,6 +223,11 @@ PHP_FUNCTION(dio_read)
ZEND_FETCH_RESOURCE(f, php_fd_t *, &r_fd, -1, le_fd_name, le_fd);
if (bytes <= 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length parameter must be greater than 0.");
RETURN_FALSE;
}
data = emalloc(bytes + 1);
res = read(f->fd, data, bytes);
if (res <= 0) {
@@ -224,6 +257,11 @@ PHP_FUNCTION(dio_write)
return;
}
if (trunc_len < 0 || trunc_len > data_len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "length must be greater or equal to zero and less then the length of the specified string.");
RETURN_FALSE;
}
ZEND_FETCH_RESOURCE(f, php_fd_t *, &r_fd, -1, le_fd_name, le_fd);
res = write(f->fd, data, trunc_len ? trunc_len : data_len);
@@ -235,6 +273,7 @@ PHP_FUNCTION(dio_write)
}
/* }}} */
#ifndef PHP_WIN32
/* {{{ proto bool dio_truncate(resource fd, int offset)
Truncate file descriptor fd to offset bytes */
PHP_FUNCTION(dio_truncate)
@@ -257,6 +296,7 @@ PHP_FUNCTION(dio_truncate)
RETURN_TRUE;
}
/* }}} */
#endif
#define ADD_FIELD(f, v) add_assoc_long_ex(return_value, (f), sizeof(f), v);
@@ -288,8 +328,10 @@ PHP_FUNCTION(dio_stat)
ADD_FIELD("gid", s.st_gid);
ADD_FIELD("device_type", s.st_rdev);
ADD_FIELD("size", s.st_size);
#ifndef PHP_WIN32
ADD_FIELD("block_size", s.st_blksize);
ADD_FIELD("blocks", s.st_blocks);
#endif
ADD_FIELD("atime", s.st_atime);
ADD_FIELD("mtime", s.st_mtime);
ADD_FIELD("ctime", s.st_ctime);
@@ -315,6 +357,7 @@ PHP_FUNCTION(dio_seek)
}
/* }}} */
#ifndef PHP_WIN32
/* {{{ proto mixed dio_fcntl(resource fd, int cmd[, mixed arg])
Perform a c library fcntl on fd */
PHP_FUNCTION(dio_fcntl)
@@ -401,7 +444,9 @@ PHP_FUNCTION(dio_fcntl)
RETURN_FALSE;
}
new_php_fd(&new_f, fcntl(f->fd, cmd, Z_LVAL_P(arg)));
if (!new_php_fd(&new_f, fcntl(f->fd, cmd, Z_LVAL_P(arg)))) {
RETURN_FALSE;
}
ZEND_REGISTER_RESOURCE(return_value, new_f, le_fd);
break;
}
@@ -415,7 +460,9 @@ PHP_FUNCTION(dio_fcntl)
}
}
/* }}} */
#endif
#ifndef PHP_WIN32
/* {{{ proto mixed dio_tcsetattr(resource fd, array args )
Perform a c library tcsetattr on fd */
PHP_FUNCTION(dio_tcsetattr)
@@ -576,6 +623,7 @@ PHP_FUNCTION(dio_tcsetattr)
RETURN_TRUE;
}
/* }}} */
#endif
/* {{{ proto void dio_close(resource fd)
Close the file descriptor given by fd */
-5
View File
@@ -1,5 +0,0 @@
this module is experimental,
its functions may change their names
or move to extension all together
so do not rely to much on them
you have been warned!
+8 -8
View File
@@ -31,7 +31,7 @@
/*
* class domattr extends domnode
* class DOMAttr extends DOMNode
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-637646024
* Since:
@@ -43,7 +43,7 @@ zend_function_entry php_dom_attr_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto void DomAttr::__construct(string name, [string value]); */
/* {{{ proto void DOMAttr::__construct(string name, [string value]); */
PHP_METHOD(domattr, __construct)
{
@@ -85,10 +85,10 @@ PHP_METHOD(domattr, __construct)
}
}
/* }}} end DomAttr::__construct */
/* }}} end DOMAttr::__construct */
/* {{{ proto name string
/* {{{ name string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-1112119403
Since:
@@ -114,7 +114,7 @@ int dom_attr_name_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto specified boolean
/* {{{ specified boolean
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-862529273
Since:
@@ -131,7 +131,7 @@ int dom_attr_specified_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto value string
/* {{{ value string
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-221662474
Since:
@@ -200,7 +200,7 @@ int dom_attr_value_write(dom_object *obj, zval *newval TSRMLS_DC)
/* {{{ proto ownerElement element
/* {{{ ownerElement DOMElement
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Attr-ownerElement
Since: DOM Level 2
@@ -236,7 +236,7 @@ int dom_attr_owner_element_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto schemaTypeInfo typeinfo
/* {{{ schemaTypeInfo DOMTypeInfo
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Attr-schemaTypeInfo
Since: DOM Level 3
+3 -3
View File
@@ -29,7 +29,7 @@
/*
* class domcdatasection extends domtext
* class DOMCdataSection extends DOMText
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-667469212
* Since:
@@ -40,7 +40,7 @@ zend_function_entry php_dom_cdatasection_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto void DomCDataSection::__construct(string value); */
/* {{{ proto void DOMCdataSection::__construct(string value); */
PHP_METHOD(domcdatasection, __construct)
{
@@ -73,6 +73,6 @@ PHP_METHOD(domcdatasection, __construct)
php_libxml_increment_node_ptr((php_libxml_node_object *)intern, nodep, (void *)intern TSRMLS_CC);
}
}
/* }}} end DomCDataSection::__construct */
/* }}} end DOMCdataSection::__construct */
#endif
+8 -8
View File
@@ -29,7 +29,7 @@
/*
* class domcharacterdata extends domnode
* class DOMCharacterData extends DOMNode
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-FF21A306
* Since:
@@ -44,7 +44,7 @@ zend_function_entry php_dom_characterdata_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto data string
/* {{{ data string
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-72AB8359
Since:
@@ -105,7 +105,7 @@ int dom_characterdata_data_write(dom_object *obj, zval *newval TSRMLS_DC)
/* }}} */
/* {{{ proto length unsigned long
/* {{{ length long
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-7D61178C
Since:
@@ -140,7 +140,7 @@ int dom_characterdata_length_read(dom_object *obj, zval **retval TSRMLS_DC)
/* }}} */
/* {{{ proto domstring dom_characterdata_substring_data(unsigned long offset, unsigned long count);
/* {{{ proto string dom_characterdata_substring_data(int offset, int count);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-6531BCCF
Since:
*/
@@ -190,7 +190,7 @@ PHP_FUNCTION(dom_characterdata_substring_data)
/* }}} end dom_characterdata_substring_data */
/* {{{ proto dom_void dom_characterdata_append_data(string arg);
/* {{{ proto void dom_characterdata_append_data(string arg);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-32791A2F
Since:
*/
@@ -215,7 +215,7 @@ PHP_FUNCTION(dom_characterdata_append_data)
/* }}} end dom_characterdata_append_data */
/* {{{ proto dom_void dom_characterdata_insert_data(unsigned long offset, string arg);
/* {{{ proto void dom_characterdata_insert_data(int offset, string arg);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-3EDB695F
Since:
*/
@@ -264,7 +264,7 @@ PHP_FUNCTION(dom_characterdata_insert_data)
/* }}} end dom_characterdata_insert_data */
/* {{{ proto dom_void dom_characterdata_delete_data(unsigned long offset, unsigned long count);
/* {{{ proto void dom_characterdata_delete_data(int offset, int count);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-7C603781
Since:
*/
@@ -320,7 +320,7 @@ PHP_FUNCTION(dom_characterdata_delete_data)
/* }}} end dom_characterdata_delete_data */
/* {{{ proto dom_void dom_characterdata_replace_data(unsigned long offset, unsigned long count, string arg);
/* {{{ proto void dom_characterdata_replace_data(int offset, int count, string arg);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-E5CBA7FB
Since:
*/
+3 -3
View File
@@ -29,7 +29,7 @@
/*
* class domcomment extends domcharacterdata
* class DOMComment extends DOMCharacterData
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-1728279322
* Since:
@@ -40,7 +40,7 @@ zend_function_entry php_dom_comment_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto void DomComment::__construct([string value]); */
/* {{{ proto void DOMComment::__construct([string value]); */
PHP_METHOD(domcomment, __construct)
{
@@ -73,5 +73,5 @@ PHP_METHOD(domcomment, __construct)
php_libxml_increment_node_ptr((php_libxml_node_object *)intern, (xmlNodePtr)nodep, (void *)intern TSRMLS_CC);
}
}
/* }}} end DomComment::__construct */
/* }}} end DOMComment::__construct */
#endif
+55 -55
View File
@@ -42,7 +42,7 @@ struct _idsIterator {
#define DOM_LOAD_FILE 1
/*
* class domdocument extends domnode
* class DOMDocument extends DOMNode
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-i-Document
* Since:
@@ -88,7 +88,7 @@ zend_function_entry php_dom_document_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto doctype documenttype
/* {{{ docType DOMDocumentType
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-B63ED1A31
Since:
@@ -124,7 +124,7 @@ int dom_document_doctype_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto implementation domimplementation
/* {{{ implementation DOMImplementation
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1B793EBA
Since:
@@ -140,7 +140,7 @@ int dom_document_implementation_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto domelement document_element documentElement
/* {{{ documentElement DOMElement
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-87CD092
Since:
@@ -174,7 +174,7 @@ int dom_document_document_element_read(dom_object *obj, zval **retval TSRMLS_DC)
/* }}} */
/* {{{ proto actual_encoding string
/* {{{ actualEncoding string
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-actualEncoding
Since: DOM Level 3
@@ -195,7 +195,7 @@ int dom_document_actual_encoding_write(dom_object *obj, zval *newval TSRMLS_DC)
/* }}} */
/* {{{ proto encoding string
/* {{{ encoding string
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-encoding
Since: DOM Level 3
*/
@@ -268,7 +268,7 @@ int dom_document_encoding_write(dom_object *obj, zval *newval TSRMLS_DC)
/* {{{ proto standalone boolean
/* {{{ standalone boolean
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-standalone
Since: DOM Level 3
@@ -334,7 +334,7 @@ int dom_document_standalone_write(dom_object *obj, zval *newval TSRMLS_DC)
/* {{{ proto version string
/* {{{ version string
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-version
Since: DOM Level 3
@@ -399,7 +399,7 @@ int dom_document_version_write(dom_object *obj, zval *newval TSRMLS_DC)
/* }}} */
/* {{{ proto strict_error_checking boolean
/* {{{ strictErrorChecking boolean
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-strictErrorChecking
Since: DOM Level 3
@@ -444,7 +444,7 @@ int dom_document_strict_error_checking_write(dom_object *obj, zval *newval TSRML
/* }}} */
/* {{{ proto formatOutput boolean
/* {{{ formatOutput boolean
readonly=no
*/
int dom_document_format_output_read(dom_object *obj, zval **retval TSRMLS_DC)
@@ -486,7 +486,7 @@ int dom_document_format_output_write(dom_object *obj, zval *newval TSRMLS_DC)
}
/* }}} */
/* {{{ proto validateonParse boolean
/* {{{ validateOnParse boolean
readonly=no
*/
int dom_document_validate_on_parse_read(dom_object *obj, zval **retval TSRMLS_DC)
@@ -529,7 +529,7 @@ int dom_document_validate_on_parse_write(dom_object *obj, zval *newval TSRMLS_DC
/* }}} */
/* {{{ proto resolveExternals boolean
/* {{{ resolveExternals boolean
readonly=no
*/
int dom_document_resolve_externals_read(dom_object *obj, zval **retval TSRMLS_DC)
@@ -572,7 +572,7 @@ int dom_document_resolve_externals_write(dom_object *obj, zval *newval TSRMLS_DC
/* }}} */
/* {{{ proto preserveWhiteSpace boolean
/* {{{ preserveWhiteSpace boolean
readonly=no
*/
int dom_document_preserve_whitespace_read(dom_object *obj, zval **retval TSRMLS_DC)
@@ -615,7 +615,7 @@ int dom_document_preserve_whitespace_write(dom_object *obj, zval *newval TSRMLS_
/* }}} */
/* {{{ proto substituteEntities boolean
/* {{{ substituteEntities boolean
readonly=no
*/
int dom_document_substitue_entities_read(dom_object *obj, zval **retval TSRMLS_DC)
@@ -658,7 +658,7 @@ int dom_document_substitue_entities_write(dom_object *obj, zval *newval TSRMLS_D
/* }}} */
/* {{{ proto document_uri string
/* {{{ documentURI string
readonly=no
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-documentURI
Since: DOM Level 3
@@ -724,7 +724,7 @@ int dom_document_document_uri_write(dom_object *obj, zval *newval TSRMLS_DC)
/* {{{ proto config domconfiguration
/* {{{ config DOMConfiguration
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-config
Since: DOM Level 3
@@ -740,7 +740,7 @@ int dom_document_config_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto domelement dom_document_create_element(string tagName [, string value]);
/* {{{ proto DOMElement dom_document_create_element(string tagName [, string value]);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-2141741547
Since:
*/
@@ -774,7 +774,7 @@ PHP_FUNCTION(dom_document_create_element)
/* }}} end dom_document_create_element */
/* {{{ proto domdocumentfragment dom_document_create_document_fragment();
/* {{{ proto DOMDocumentFragment dom_document_create_document_fragment();
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-35CB04B5
Since:
*/
@@ -802,7 +802,7 @@ PHP_FUNCTION(dom_document_create_document_fragment)
/* }}} end dom_document_create_document_fragment */
/* {{{ proto domtext dom_document_create_text_node(string data);
/* {{{ proto DOMText dom_document_create_text_node(string data);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1975348127
Since:
*/
@@ -831,7 +831,7 @@ PHP_FUNCTION(dom_document_create_text_node)
/* }}} end dom_document_create_text_node */
/* {{{ proto domcomment dom_document_create_comment(string data);
/* {{{ proto DOMComment dom_document_create_comment(string data);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1334481328
Since:
*/
@@ -860,7 +860,7 @@ PHP_FUNCTION(dom_document_create_comment)
/* }}} end dom_document_create_comment */
/* {{{ proto domcdatasection dom_document_create_cdatasection(string data);
/* {{{ proto DOMCdataSection dom_document_create_cdatasection(string data);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-D26C0AF8
Since:
*/
@@ -889,7 +889,7 @@ PHP_FUNCTION(dom_document_create_cdatasection)
/* }}} end dom_document_create_cdatasection */
/* {{{ proto domprocessinginstruction dom_document_create_processing_instruction(string target, string data);
/* {{{ proto DOMProcessingInstruction dom_document_create_processing_instruction(string target, string data);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-135944439
Since:
*/
@@ -925,7 +925,7 @@ PHP_FUNCTION(dom_document_create_processing_instruction)
/* }}} end dom_document_create_processing_instruction */
/* {{{ proto domattr dom_document_create_attribute(string name);
/* {{{ proto DOMAttr dom_document_create_attribute(string name);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1084891198
Since:
*/
@@ -960,7 +960,7 @@ PHP_FUNCTION(dom_document_create_attribute)
/* }}} end dom_document_create_attribute */
/* {{{ proto domentityreference dom_document_create_entity_reference(string name);
/* {{{ proto DOMEntityReference dom_document_create_entity_reference(string name);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-392B75AE
Since:
*/
@@ -994,7 +994,7 @@ PHP_FUNCTION(dom_document_create_entity_reference)
/* }}} end dom_document_create_entity_reference */
/* {{{ proto domnodelist dom_document_get_elements_by_tag_name(string tagname);
/* {{{ proto DOMNodeList dom_document_get_elements_by_tag_name(string tagname);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-A6C9094
Since:
*/
@@ -1016,12 +1016,12 @@ PHP_FUNCTION(dom_document_get_elements_by_tag_name)
php_dom_create_interator(return_value, DOM_NODELIST TSRMLS_CC);
namednode = (dom_object *)zend_objects_get_address(return_value TSRMLS_CC);
local = xmlCharStrndup(name, name_len);
dom_namednode_iter(intern, 0, namednode, NULL, local, NULL);
dom_namednode_iter(intern, 0, namednode, NULL, local, NULL TSRMLS_CC);
}
/* }}} end dom_document_get_elements_by_tag_name */
/* {{{ proto domnode dom_document_import_node(node importedNode, boolean deep);
/* {{{ proto DOMNode dom_document_import_node(DOMNode importedNode, boolean deep);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Core-Document-importNode
Since: DOM Level 2
*/
@@ -1063,7 +1063,7 @@ PHP_FUNCTION(dom_document_import_node)
/* }}} end dom_document_import_node */
/* {{{ proto domelement dom_document_create_element_ns(string namespaceURI, string qualifiedName);
/* {{{ proto DOMElement dom_document_create_element_ns(string namespaceURI, string qualifiedName [,string value]);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-DocCrElNS
Since: DOM Level 2
*/
@@ -1073,13 +1073,13 @@ PHP_FUNCTION(dom_document_create_element_ns)
xmlDocPtr docp;
xmlNodePtr nodep = NULL;
xmlNsPtr nsptr = NULL;
int ret, uri_len = 0, name_len = 0;
char *uri, *name;
int ret, uri_len = 0, name_len = 0, value_len = 0;
char *uri, *name, *value = NULL;
char *localname = NULL, *prefix = NULL;
int errorcode;
dom_object *intern;
if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_document_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s|s", &id, dom_document_class_entry, &uri, &uri_len, &name, &name_len, &value, &value_len) == FAILURE) {
return;
}
@@ -1089,7 +1089,7 @@ PHP_FUNCTION(dom_document_create_element_ns)
if (errorcode == 0) {
if (xmlValidateName((xmlChar *) localname, 0) == 0) {
nodep = xmlNewDocNode (docp, NULL, localname, NULL);
nodep = xmlNewDocNode (docp, NULL, localname, value);
if (nodep != NULL && uri != NULL) {
nsptr = xmlSearchNsByHref (nodep->doc, nodep, uri);
if (nsptr == NULL) {
@@ -1127,7 +1127,7 @@ PHP_FUNCTION(dom_document_create_element_ns)
/* }}} end dom_document_create_element_ns */
/* {{{ proto domattr dom_document_create_attribute_ns(string namespaceURI, string qualifiedName);
/* {{{ proto DOMAttr dom_document_create_attribute_ns(string namespaceURI, string qualifiedName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-DocCrAttrNS
Since: DOM Level 2
*/
@@ -1193,7 +1193,7 @@ PHP_FUNCTION(dom_document_create_attribute_ns)
/* }}} end dom_document_create_attribute_ns */
/* {{{ proto domnodelist dom_document_get_elements_by_tag_name_ns(string namespaceURI, string localName);
/* {{{ proto DOMNodeList dom_document_get_elements_by_tag_name_ns(string namespaceURI, string localName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-getElBTNNS
Since: DOM Level 2
*/
@@ -1216,12 +1216,12 @@ PHP_FUNCTION(dom_document_get_elements_by_tag_name_ns)
namednode = (dom_object *)zend_objects_get_address(return_value TSRMLS_CC);
local = xmlCharStrndup(name, name_len);
nsuri = xmlCharStrndup(uri, uri_len);
dom_namednode_iter(intern, 0, namednode, NULL, local, nsuri);
dom_namednode_iter(intern, 0, namednode, NULL, local, nsuri TSRMLS_CC);
}
/* }}} end dom_document_get_elements_by_tag_name_ns */
/* {{{ proto domelement dom_document_get_element_by_id(string elementId);
/* {{{ proto DOMElement dom_document_get_element_by_id(string elementId);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-getElBId
Since: DOM Level 2
*/
@@ -1252,7 +1252,7 @@ PHP_FUNCTION(dom_document_get_element_by_id)
/* }}} end dom_document_get_element_by_id */
/* {{{ proto domnode dom_document_adopt_node(node source);
/* {{{ proto DOMNode dom_document_adopt_node(DOMNode source);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-adoptNode
Since: DOM Level 3
*/
@@ -1263,7 +1263,7 @@ PHP_FUNCTION(dom_document_adopt_node)
/* }}} end dom_document_adopt_node */
/* {{{ proto dom_void dom_document_normalize_document();
/* {{{ proto void dom_document_normalize_document();
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-normalizeDocument
Since: DOM Level 3
*/
@@ -1284,7 +1284,7 @@ PHP_FUNCTION(dom_document_normalize_document)
/* }}} end dom_document_normalize_document */
/* {{{ proto domnode dom_document_rename_node(node n, string namespaceURI, string qualifiedName);
/* {{{ proto DOMNode dom_document_rename_node(node n, string namespaceURI, string qualifiedName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-renameNode
Since: DOM Level 3
*/
@@ -1294,7 +1294,7 @@ PHP_FUNCTION(dom_document_rename_node)
}
/* }}} end dom_document_rename_node */
/* {{{ proto void DomDocument::__construct([string version], [string encoding]); */
/* {{{ proto void DOMDocument::__construct([string version], [string encoding]); */
PHP_METHOD(domdocument, __construct)
{
@@ -1337,7 +1337,7 @@ PHP_METHOD(domdocument, __construct)
php_libxml_increment_node_ptr((php_libxml_node_object *)intern, (xmlNodePtr)docp, (void *)intern TSRMLS_CC);
}
}
/* }}} end dom_document_document */
/* }}} end DOMDocument::__construct */
char *_dom_get_valid_file_path(char *source, char *resolved_path, int resolved_path_len TSRMLS_DC) {
xmlURI *uri;
@@ -1544,7 +1544,7 @@ static void dom_parse_document(INTERNAL_FUNCTION_PARAMETERS, int mode) {
}
/* }}} end dom_parser_document */
/* {{{ proto boolean domnode dom_document_load(string source);
/* {{{ proto DOMNode dom_document_load(string source);
URL: http://www.w3.org/TR/DOM-Level-3-LS/load-save.html#LS-DocumentLS-load
Since: DOM Level 3
*/
@@ -1554,7 +1554,7 @@ PHP_METHOD(domdocument, load)
}
/* }}} end dom_document_load */
/* {{{ proto boolean domnode dom_document_loadxml(string source);
/* {{{ proto DOMNode dom_document_loadxml(string source);
URL: http://www.w3.org/TR/DOM-Level-3-LS/load-save.html#LS-DocumentLS-loadXML
Since: DOM Level 3
*/
@@ -1564,7 +1564,7 @@ PHP_METHOD(domdocument, loadXML)
}
/* }}} end dom_document_loadxml */
/* {{{ proto long domnode dom_document_save(string file);
/* {{{ proto int dom_document_save(string file);
Convenience method to save to file
*/
PHP_FUNCTION(dom_document_save)
@@ -1600,7 +1600,7 @@ PHP_FUNCTION(dom_document_save)
}
/* }}} end dom_document_save */
/* {{{ proto string domnode dom_document_savexml([node n]);
/* {{{ proto string dom_document_savexml([node n]);
URL: http://www.w3.org/TR/DOM-Level-3-LS/load-save.html#LS-DocumentLS-saveXML
Since: DOM Level 3
*/
@@ -1729,7 +1729,7 @@ PHP_FUNCTION(dom_document_xinclude)
}
/* {{{ proto string domnode dom_document_validate();
/* {{{ proto boolean dom_document_validate();
Since: DOM extended
*/
PHP_FUNCTION(dom_document_validate)
@@ -1842,19 +1842,19 @@ _dom_document_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type)
}
}
/* {{{ proto boolean domnode _dom_document_schema_validate(string filename); */
/* {{{ proto boolean dom_document_schema_validate_file(string filename); */
PHP_FUNCTION(dom_document_schema_validate_file)
{
_dom_document_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_FILE);
}
/* }}} end _dom_document_schema_validate */
/* }}} end dom_document_schema_validate_file */
/* {{{ proto boolean domnode _dom_document_schema_validate(string source); */
/* {{{ proto boolean dom_document_schema_validate(string source); */
PHP_FUNCTION(dom_document_schema_validate_xml)
{
_dom_document_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_STRING);
}
/* }}} end _dom_document_schema_validate */
/* }}} end dom_document_schema_validate */
static void
@@ -1932,14 +1932,14 @@ _dom_document_relaxNG_validate(INTERNAL_FUNCTION_PARAMETERS, int type)
}
}
/* {{{ proto boolean domnode dom_document_relaxNG_validate_file(string filename); */
/* {{{ proto boolean dom_document_relaxNG_validate_file(string filename); */
PHP_FUNCTION(dom_document_relaxNG_validate_file)
{
_dom_document_relaxNG_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_FILE);
}
/* }}} end dom_document_relaxNG_validate_file */
/* {{{ proto boolean domnode dom_document_relaxNG_validate_xml(string source); */
/* {{{ proto boolean dom_document_relaxNG_validate_xml(string source); */
PHP_FUNCTION(dom_document_relaxNG_validate_xml)
{
_dom_document_relaxNG_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_STRING);
@@ -2022,7 +2022,7 @@ static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode)
}
}
/* {{{ proto boolean domnode dom_document_load_html_file(string source);
/* {{{ proto DOMNode dom_document_load_html_file(string source);
Since: DOM extended
*/
PHP_METHOD(domdocument, loadHTMLFile)
@@ -2031,7 +2031,7 @@ PHP_METHOD(domdocument, loadHTMLFile)
}
/* }}} end dom_document_load_html_file */
/* {{{ proto boolean domnode dom_document_load_html(string source);
/* {{{ proto DOMNode dom_document_load_html(string source);
Since: DOM extended
*/
PHP_METHOD(domdocument, loadHTML)
@@ -2040,7 +2040,7 @@ PHP_METHOD(domdocument, loadHTML)
}
/* }}} end dom_document_load_html */
/* {{{ proto long dom_document_save_html_file(string file);
/* {{{ proto int dom_document_save_html_file(string file);
Convenience method to save to file as html
*/
PHP_FUNCTION(dom_document_save_html_file)
+3 -3
View File
@@ -29,7 +29,7 @@
/*
* class domdocumentfragment extends domnode
* class DOMDocumentFragment extends DOMNode
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-B63ED1A3
* Since:
@@ -40,7 +40,7 @@ zend_function_entry php_dom_documentfragment_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto void DomDocumentFragment::__construct(); */
/* {{{ proto void DOMDocumentFragment::__construct(); */
PHP_METHOD(domdocumentfragment, __construct)
{
@@ -72,5 +72,5 @@ PHP_METHOD(domdocumentfragment, __construct)
php_libxml_increment_node_ptr((php_libxml_node_object *)intern, nodep, (void *)intern TSRMLS_CC);
}
}
/* }}} end DomDocumentFragment::__construct */
/* }}} end DOMDocumentFragment::__construct */
#endif
+9 -11
View File
@@ -28,7 +28,7 @@
#include "php_dom.h"
/*
* class domdocumenttype extends domnode
* class DOMDocumentType extends DOMNode
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-412266927
* Since:
@@ -38,9 +38,7 @@ zend_function_entry php_dom_documenttype_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ attribute protos, not implemented yet */
/* {{{ proto name string
/* {{{ name string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1844763134
Since:
@@ -66,7 +64,7 @@ int dom_documenttype_name_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto entities namednodemap
/* {{{ entities DOMNamedNodeMap
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1788794630
Since:
@@ -90,7 +88,7 @@ int dom_documenttype_entities_read(dom_object *obj, zval **retval TSRMLS_DC)
entityht = (xmlHashTable *) doctypep->entities;
intern = (dom_object *)zend_objects_get_address(*retval TSRMLS_CC);
dom_namednode_iter(obj, XML_ENTITY_NODE, intern, entityht, NULL, NULL);
dom_namednode_iter(obj, XML_ENTITY_NODE, intern, entityht, NULL, NULL TSRMLS_CC);
return SUCCESS;
}
@@ -99,7 +97,7 @@ int dom_documenttype_entities_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto notations namednodemap
/* {{{ notations DOMNamedNodeMap
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-D46829EF
Since:
@@ -123,7 +121,7 @@ int dom_documenttype_notations_read(dom_object *obj, zval **retval TSRMLS_DC)
notationht = (xmlHashTable *) doctypep->notations;
intern = (dom_object *)zend_objects_get_address(*retval TSRMLS_CC);
dom_namednode_iter(obj, XML_NOTATION_NODE, intern, notationht, NULL, NULL);
dom_namednode_iter(obj, XML_NOTATION_NODE, intern, notationht, NULL, NULL TSRMLS_CC);
return SUCCESS;
}
@@ -132,7 +130,7 @@ int dom_documenttype_notations_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto public_id string
/* {{{ publicId string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-Core-DocType-publicId
Since: DOM Level 2
@@ -162,7 +160,7 @@ int dom_documenttype_public_id_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto system_id string
/* {{{ systemId string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-Core-DocType-systemId
Since: DOM Level 2
@@ -191,7 +189,7 @@ int dom_documenttype_system_id_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto internal_subset string
/* {{{ internalSubset string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-Core-DocType-internalSubset
Since: DOM Level 2
+6 -6
View File
@@ -41,7 +41,7 @@ zend_function_entry php_dom_domerror_class_functions[] = {
/* {{{ attribute protos, not implemented yet */
/* {{{ proto severity unsigned short
/* {{{ severity unsigned short
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ERROR-DOMError-severity
Since:
@@ -57,7 +57,7 @@ int dom_domerror_severity_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto message string
/* {{{ message string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ERROR-DOMError-message
Since:
@@ -73,7 +73,7 @@ int dom_domerror_message_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto type string
/* {{{ type string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ERROR-DOMError-type
Since:
@@ -89,7 +89,7 @@ int dom_domerror_type_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto relatedException object
/* {{{ relatedException object
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ERROR-DOMError-relatedException
Since:
@@ -105,7 +105,7 @@ int dom_domerror_related_exception_read(dom_object *obj, zval **retval TSRMLS_DC
/* {{{ proto relatedData domobject
/* {{{ relatedData domobject
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ERROR-DOMError-relatedData
Since:
@@ -121,7 +121,7 @@ int dom_domerror_related_data_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto location domlocator
/* {{{ location domlocator
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ERROR-DOMError-location
Since:
+1 -1
View File
@@ -29,7 +29,7 @@
/*
* class domexception
* class DOMException
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-17189187
* Since:
+4 -7
View File
@@ -28,7 +28,7 @@
#include "php_dom.h"
/*
* class domimplementation
* class DOMImplementation
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-102161490
* Since:
@@ -42,9 +42,6 @@ zend_function_entry php_dom_domimplementation_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ attribute protos, not implemented yet */
/* {{{ proto boolean dom_domimplementation_has_feature(string feature, string version);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-5CED94D7
Since:
@@ -67,7 +64,7 @@ PHP_METHOD(domimplementation, hasFeature)
/* }}} end dom_domimplementation_has_feature */
/* {{{ proto domdocumenttype dom_domimplementation_create_document_type(string qualifiedName, string publicId, string systemId);
/* {{{ proto DOMDocumentType dom_domimplementation_create_document_type(string qualifiedName, string publicId, string systemId);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Level-2-Core-DOM-createDocType
Since: DOM Level 2
*/
@@ -121,7 +118,7 @@ PHP_METHOD(domimplementation, createDocumentType)
/* }}} end dom_domimplementation_create_document_type */
/* {{{ proto domdocument dom_domimplementation_create_document(string namespaceURI, string qualifiedName, documenttype doctype);
/* {{{ proto DOMDocument dom_domimplementation_create_document(string namespaceURI, string qualifiedName, DOMDocumentType doctype);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Level-2-Core-DOM-createDocument
Since: DOM Level 2
*/
@@ -224,7 +221,7 @@ PHP_METHOD(domimplementation, createDocument)
/* }}} end dom_domimplementation_create_document */
/* {{{ proto domnode dom_domimplementation_get_feature(string feature, string version);
/* {{{ proto DOMNode dom_domimplementation_get_feature(string feature, string version);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMImplementation3-getFeature
Since: DOM Level 3
*/
+2 -2
View File
@@ -42,7 +42,7 @@ zend_function_entry php_dom_domimplementationlist_class_functions[] = {
/* {{{ attribute protos, not implemented yet */
/* {{{ proto length unsigned long
/* {{{ length unsigned long
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMImplementationList-length
Since:
@@ -59,7 +59,7 @@ int dom_domimplementationlist_length_read(dom_object *obj, zval **retval TSRMLS_
/* {{{ proto domdomimplementation dom_domimplementationlist_item(unsigned long index);
/* {{{ proto domdomimplementation dom_domimplementationlist_item(int index);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMImplementationList-item
Since:
*/
+5 -5
View File
@@ -41,7 +41,7 @@ zend_function_entry php_dom_domlocator_class_functions[] = {
/* {{{ attribute protos, not implemented yet */
/* {{{ proto line_number long
/* {{{ line_number long
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMLocator-line-number
Since:
@@ -57,7 +57,7 @@ int dom_domlocator_line_number_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto column_number long
/* {{{ column_number long
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMLocator-column-number
Since:
@@ -73,7 +73,7 @@ int dom_domlocator_column_number_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto offset long
/* {{{ offset long
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMLocator-offset
Since:
@@ -89,7 +89,7 @@ int dom_domlocator_offset_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto related_node node
/* {{{ related_node node
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMLocator-node
Since:
@@ -105,7 +105,7 @@ int dom_domlocator_related_node_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto uri string
/* {{{ uri string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMLocator-uri
Since:
+2 -2
View File
@@ -42,7 +42,7 @@ zend_function_entry php_dom_domstringlist_class_functions[] = {
/* {{{ attribute protos, not implemented yet */
/* {{{ proto length unsigned long
/* {{{ length unsigned long
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMStringList-length
Since:
@@ -59,7 +59,7 @@ int dom_domstringlist_length_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto domstring dom_domstringlist_item(unsigned long index);
/* {{{ proto domstring dom_domstringlist_item(int index);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMStringList-item
Since:
*/
+23 -23
View File
@@ -29,7 +29,7 @@
/*
* class domelement extends domnode
* class DOMElement extends DOMNode
*
* URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-745549614
* Since:
@@ -58,7 +58,7 @@ zend_function_entry php_dom_element_class_functions[] = {
{NULL, NULL, NULL}
};
/* {{{ proto void DomElement::__construct(string name, [string value], [string uri]); */
/* {{{ proto void DOMElement::__construct(string name, [string value], [string uri]); */
PHP_METHOD(domelement, __construct)
{
@@ -135,9 +135,9 @@ PHP_METHOD(domelement, __construct)
php_libxml_increment_node_ptr((php_libxml_node_object *)intern, nodep, (void *)intern TSRMLS_CC);
}
}
/* }}} end DomElement::__construct */
/* }}} end DOMElement::__construct */
/* {{{ proto tagName string
/* {{{ tagName string
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-104682815
Since:
@@ -174,7 +174,7 @@ int dom_element_tag_name_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto schemaTypeInfo typeinfo
/* {{{ schemaTypeInfo typeinfo
readonly=yes
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Element-schemaTypeInfo
Since: DOM Level 3
@@ -190,7 +190,7 @@ int dom_element_schema_type_info_read(dom_object *obj, zval **retval TSRMLS_DC)
/* {{{ proto domstring dom_element_get_attribute(string name);
/* {{{ proto string dom_element_get_attribute(string name);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-666EE0F9
Since:
*/
@@ -219,7 +219,7 @@ PHP_FUNCTION(dom_element_get_attribute)
/* }}} end dom_element_get_attribute */
/* {{{ proto dom_void dom_element_set_attribute(string name, string value);
/* {{{ proto void dom_element_set_attribute(string name, string value);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-F68F082
Since:
*/
@@ -265,7 +265,7 @@ PHP_FUNCTION(dom_element_set_attribute)
/* }}} end dom_element_set_attribute */
/* {{{ proto dom_void dom_element_remove_attribute(string name);
/* {{{ proto void dom_element_remove_attribute(string name);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-6D6AC0F9
Since:
*/
@@ -308,7 +308,7 @@ PHP_FUNCTION(dom_element_remove_attribute)
/* }}} end dom_element_remove_attribute */
/* {{{ proto domattr dom_element_get_attribute_node(string name);
/* {{{ proto DOMAttr dom_element_get_attribute_node(string name);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-217A91B8
Since:
*/
@@ -337,7 +337,7 @@ PHP_FUNCTION(dom_element_get_attribute_node)
/* }}} end dom_element_get_attribute_node */
/* {{{ proto domattr dom_element_set_attribute_node(attr newAttr);
/* {{{ proto DOMAttr dom_element_set_attribute_node(DOMAttr newAttr);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-887236154
Since:
*/
@@ -395,7 +395,7 @@ PHP_FUNCTION(dom_element_set_attribute_node)
/* }}} end dom_element_set_attribute_node */
/* {{{ proto domattr dom_element_remove_attribute_node(attr oldAttr);
/* {{{ proto DOMAttr dom_element_remove_attribute_node(DOMAttr oldAttr);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-D589198
Since:
*/
@@ -433,7 +433,7 @@ PHP_FUNCTION(dom_element_remove_attribute_node)
/* }}} end dom_element_remove_attribute_node */
/* {{{ proto domnodelist dom_element_get_elements_by_tag_name(string name);
/* {{{ proto DOMNodeList dom_element_get_elements_by_tag_name(string name);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1938918D
Since:
*/
@@ -455,12 +455,12 @@ PHP_FUNCTION(dom_element_get_elements_by_tag_name)
php_dom_create_interator(return_value, DOM_NODELIST TSRMLS_CC);
namednode = (dom_object *)zend_objects_get_address(return_value TSRMLS_CC);
local = xmlCharStrndup(name, name_len);
dom_namednode_iter(intern, 0, namednode, NULL, local, NULL);
dom_namednode_iter(intern, 0, namednode, NULL, local, NULL TSRMLS_CC);
}
/* }}} end dom_element_get_elements_by_tag_name */
/* {{{ proto domstring dom_element_get_attribute_ns(string namespaceURI, string localName);
/* {{{ proto string dom_element_get_attribute_ns(string namespaceURI, string localName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElGetAttrNS
Since: DOM Level 2
*/
@@ -501,7 +501,7 @@ PHP_FUNCTION(dom_element_get_attribute_ns)
/* }}} end dom_element_get_attribute_ns */
/* {{{ proto dom_void dom_element_set_attribute_ns(string namespaceURI, string qualifiedName, string value);
/* {{{ proto void dom_element_set_attribute_ns(string namespaceURI, string qualifiedName, string value);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetAttrNS
Since: DOM Level 2
*/
@@ -599,7 +599,7 @@ PHP_FUNCTION(dom_element_set_attribute_ns)
/* }}} end dom_element_set_attribute_ns */
/* {{{ proto dom_void dom_element_remove_attribute_ns(string namespaceURI, string localName);
/* {{{ proto void dom_element_remove_attribute_ns(string namespaceURI, string localName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElRemAtNS
Since: DOM Level 2
*/
@@ -657,7 +657,7 @@ PHP_FUNCTION(dom_element_remove_attribute_ns)
/* }}} end dom_element_remove_attribute_ns */
/* {{{ proto domattr dom_element_get_attribute_node_ns(string namespaceURI, string localName);
/* {{{ proto DOMAttr dom_element_get_attribute_node_ns(string namespaceURI, string localName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElGetAtNodeNS
Since: DOM Level 2
*/
@@ -688,7 +688,7 @@ PHP_FUNCTION(dom_element_get_attribute_node_ns)
/* }}} end dom_element_get_attribute_node_ns */
/* {{{ proto domattr dom_element_set_attribute_node_ns(attr newAttr);
/* {{{ proto DOMAttr dom_element_set_attribute_node_ns(DOMAttr newAttr);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetAtNodeNS
Since: DOM Level 2
*/
@@ -754,7 +754,7 @@ PHP_FUNCTION(dom_element_set_attribute_node_ns)
/* {{{ proto domnodelist dom_element_get_elements_by_tag_name_ns(string namespaceURI, string localName);
/* {{{ proto DOMNodeList dom_element_get_elements_by_tag_name_ns(string namespaceURI, string localName);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-A6C90942
Since: DOM Level 2
*/
@@ -777,7 +777,7 @@ PHP_FUNCTION(dom_element_get_elements_by_tag_name_ns)
namednode = (dom_object *)zend_objects_get_address(return_value TSRMLS_CC);
local = xmlCharStrndup(name, name_len);
nsuri = xmlCharStrndup(uri, uri_len);
dom_namednode_iter(intern, 0, namednode, NULL, local, nsuri);
dom_namednode_iter(intern, 0, namednode, NULL, local, nsuri TSRMLS_CC);
}
/* }}} end dom_element_get_elements_by_tag_name_ns */
@@ -850,7 +850,7 @@ PHP_FUNCTION(dom_element_has_attribute_ns)
/* }}} end dom_element_has_attribute_ns */
/* {{{ proto dom_void dom_element_set_id_attribute(string name, boolean isId);
/* {{{ proto void dom_element_set_id_attribute(string name, boolean isId);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetIdAttr
Since: DOM Level 3
*/
@@ -861,7 +861,7 @@ PHP_FUNCTION(dom_element_set_id_attribute)
/* }}} end dom_element_set_id_attribute */
/* {{{ proto dom_void dom_element_set_id_attribute_ns(string namespaceURI, string localName, boolean isId);
/* {{{ proto void dom_element_set_id_attribute_ns(string namespaceURI, string localName, boolean isId);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetIdAttrNS
Since: DOM Level 3
*/
@@ -872,7 +872,7 @@ PHP_FUNCTION(dom_element_set_id_attribute_ns)
/* }}} end dom_element_set_id_attribute_ns */
/* {{{ proto dom_void dom_element_set_id_attribute_node(attr idAttr, boolean isId);
/* {{{ proto void dom_element_set_id_attribute_node(attr idAttr, boolean isId);
URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetIdAttrNode
Since: DOM Level 3
*/
Loaded 100 of 739 files, more files were not shown because too many files have changed in this diff. Show more