johannes Thu, 11 Feb 2010 17:36:40 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=294893
Log:
merge r292620: Fixed bug #50558 (Broken object model when extending tidy)
(pierrick)
Bug: http://bugs.php.net/50558 (Closed) Broken object model when extending tidy
Changed paths:
_U php/php-src/branches/PHP_5_3_2/
U php/php-src/branches/PHP_5_3_2/NEWS
_U php/php-src/branches/PHP_5_3_2/ext/tidy/tests/
A + php/php-src/branches/PHP_5_3_2/ext/tidy/tests/bug_50558.phpt
(from
php/php-src/branches/PHP_5_3/ext/tidy/tests/bug_50558.phpt:r292620)
U php/php-src/branches/PHP_5_3_2/ext/tidy/tidy.c
_U
php/php-src/branches/PHP_5_3_2/tests/security/open_basedir_parse_ini_file.phpt
Property changes on: php/php-src/branches/PHP_5_3_2
___________________________________________________________________
Modified: svn:mergeinfo
- /php/php-src/branches/PHP_5_3:292504,292574,292594-292595,292611,292624,292630,292632-292635,292654,292677,292682-292683,292693,292716,292719,292762,292765,292771,292777,292823,293051,293075,293114,293126,293131,293144,293146,293152,293175-293176,293180,293216,293235,293253,293268,293341,293380,293400,293442,293447,293466,293487,293502,293538,293548,293558,293588,293590,293597,293627,293644,293653,293655,293699,293721,293726-293728,293730,293732,293735,293762,293768,293804,293815-293816,293862,293894,293896-293897,293901-293906,293917-293918,293965-293966,293974,293976-293977,293985,293998,294040,294053,294075,294077-294078,294081,294089,294094,294100,294102,294104,294126-294127,294129,294164,294251-294253,294255,294259-294261,294265,294267,294269,294272,294278,294285,294302-294304,294307-294308,294310,294312-294313,294315,294317,294320-294323,294333-294336,294353,294418,294421,294487,294498,294532,294571,294695,294697,294724,294762,294814,294816,294825,294849,294854-294855
/php/php-src/trunk:284726
+ /php/php-src/branches/PHP_5_3:292504,292574,292594-292595,292611,292620,292624,292630,292632-292635,292654,292677,292682-292683,292693,292716,292719,292762,292765,292771,292777,292823,293051,293075,293114,293126,293131,293144,293146,293152,293175-293176,293180,293216,293235,293253,293268,293341,293380,293400,293442,293447,293466,293487,293502,293538,293548,293558,293588,293590,293597,293627,293644,293653,293655,293699,293721,293726-293728,293730,293732,293735,293762,293768,293804,293815-293816,293862,293894,293896-293897,293901-293906,293917-293918,293965-293966,293974,293976-293977,293985,293998,294040,294053,294075,294077-294078,294081,294089,294094,294100,294102,294104,294126-294127,294129,294164,294251-294253,294255,294259-294261,294265,294267,294269,294272,294278,294285,294302-294304,294307-294308,294310,294312-294313,294315,294317,294320-294323,294333-294336,294353,294418,294421,294487,294498,294532,294571,294695,294697,294724,294762,294814,294816,294825,294849,294854-294855
/php/php-src/trunk:284726
Modified: php/php-src/branches/PHP_5_3_2/NEWS
===================================================================
--- php/php-src/branches/PHP_5_3_2/NEWS 2010-02-11 17:24:43 UTC (rev 294892)
+++ php/php-src/branches/PHP_5_3_2/NEWS 2010-02-11 17:36:40 UTC (rev 294893)
@@ -102,6 +102,7 @@
- Fixed memory leak in extension loading when an error occurs on Windows.
(Pierre)
+- Fixed bug #50558 (Broken object model when extending tidy). (Pierrick)
- Fixed bug #50540 (Crash while running ldap_next_reference test cases).
(Sriram)
- Fixed bug #50519 (segfault in garbage collection when using set_error_handler
Property changes on: php/php-src/branches/PHP_5_3_2/ext/tidy/tests
___________________________________________________________________
Modified: svn:mergeinfo
- /php/php-src/branches/PHP_5_3/ext/tidy/tests:292562,292566,292571,292574,292635,292716,292719,292765,293146,293152,293175-293176,293180,293216,293235,293253,293380,293400,293442,293447,293466,293487,293502,293538,293548,293558,293588,293590,293597,293627,293644,293653,293655,293699,293721,293726-293728,293730,293732,293735,293762,293768,293804,293815-293816,293862,293894,293896-293897,293901-293906,293917-293918,293965-293966,293976-293977,293985,293998,294040,294053,294075,294077-294078,294081,294089,294094,294100,294102,294104,294126-294127,294129,294164,294251-294253,294255,294259-294261,294265,294267,294269,294272,294278,294285,294302-294304,294307-294308,294310,294312-294313,294315,294317,294320-294323,294333-294336,294353,294418,294421,294487,294498,294532,294571,294695,294697,294724,294762,294814,294816,294825,294849,294854-294855
/php/php-src/trunk/ext/tidy/tests:29815-29816,284726,287798-287941
+ /php/php-src/branches/PHP_5_3/ext/tidy/tests:292562,292566,292571,292574,292620,292635,292716,292719,292765,293146,293152,293175-293176,293180,293216,293235,293253,293380,293400,293442,293447,293466,293487,293502,293538,293548,293558,293588,293590,293597,293627,293644,293653,293655,293699,293721,293726-293728,293730,293732,293735,293762,293768,293804,293815-293816,293862,293894,293896-293897,293901-293906,293917-293918,293965-293966,293976-293977,293985,293998,294040,294053,294075,294077-294078,294081,294089,294094,294100,294102,294104,294126-294127,294129,294164,294251-294253,294255,294259-294261,294265,294267,294269,294272,294278,294285,294302-294304,294307-294308,294310,294312-294313,294315,294317,294320-294323,294333-294336,294353,294418,294421,294487,294498,294532,294571,294695,294697,294724,294762,294814,294816,294825,294849,294854-294855
/php/php-src/trunk/ext/tidy/tests:29815-29816,284726,287798-287941
Copied: php/php-src/branches/PHP_5_3_2/ext/tidy/tests/bug_50558.phpt (from rev 292620, php/php-src/branches/PHP_5_3/ext/tidy/tests/bug_50558.phpt)
===================================================================
--- php/php-src/branches/PHP_5_3_2/ext/tidy/tests/bug_50558.phpt (rev 0)
+++ php/php-src/branches/PHP_5_3_2/ext/tidy/tests/bug_50558.phpt 2010-02-11 17:36:40 UTC (rev 294893)
@@ -0,0 +1,28 @@
+--TEST--
+Bug #50558 - Broken object model when extending tidy
+--SKIPIF--
+<?php if (!extension_loaded("tidy")) print "skip"; ?>
+--FILE--
+<?php
+class MyTidy extends tidy
+{
+ // foo
+}
+
+function doSomething(MyTidy $o)
+{
+ var_dump($o);
+}
+
+$o = new MyTidy();
+var_dump($o instanceof MyTidy);
+doSomething($o);
+?>
+--EXPECTF--
+bool(true)
+object(MyTidy)#%d (%d) {
+ ["errorBuffer"]=>
+ NULL
+ ["value"]=>
+ NULL
+}
Modified: php/php-src/branches/PHP_5_3_2/ext/tidy/tidy.c
===================================================================
--- php/php-src/branches/PHP_5_3_2/ext/tidy/tidy.c 2010-02-11 17:24:43 UTC (rev 294892)
+++ php/php-src/branches/PHP_5_3_2/ext/tidy/tidy.c 2010-02-11 17:36:40 UTC (rev 294893)
@@ -206,8 +206,6 @@
static void tidy_object_free_storage(void * TSRMLS_DC);
static zend_object_value tidy_object_new_node(zend_class_entry * TSRMLS_DC);
static zend_object_value tidy_object_new_doc(zend_class_entry * TSRMLS_DC);
-static zend_class_entry *tidy_get_ce_node(const zval * TSRMLS_DC);
-static zend_class_entry *tidy_get_ce_doc(const zval * TSRMLS_DC);
static zval * tidy_instanciate(zend_class_entry *, zval * TSRMLS_DC);
static int tidy_doc_cast_handler(zval *, zval *, int TSRMLS_DC);
static int tidy_node_cast_handler(zval *, zval *, int TSRMLS_DC);
@@ -742,16 +740,6 @@
return retval;
}
-static zend_class_entry *tidy_get_ce_node(const zval *object TSRMLS_DC)
-{
- return tidy_ce_node;
-}
-
-static zend_class_entry *tidy_get_ce_doc(const zval *object TSRMLS_DC)
-{
- return tidy_ce_doc;
-}
-
static zval * tidy_instanciate(zend_class_entry *pce, zval *object TSRMLS_DC)
{
if (!object) {
@@ -1066,9 +1054,6 @@
REGISTER_TIDY_CLASS(tidy, doc, NULL, 0);
REGISTER_TIDY_CLASS(tidyNode, node, NULL, ZEND_ACC_FINAL_CLASS);
- tidy_object_handlers_doc.get_class_entry = tidy_get_ce_doc;
- tidy_object_handlers_node.get_class_entry = tidy_get_ce_node;
-
tidy_object_handlers_doc.cast_object = tidy_doc_cast_handler;
tidy_object_handlers_node.cast_object = tidy_node_cast_handler;
Property changes on: php/php-src/branches/PHP_5_3_2/tests/security/open_basedir_parse_ini_file.phpt
___________________________________________________________________
Modified: svn:mergeinfo
- /php/php-src/branches/PHP_5_3/tests/security/open_basedir_parse_ini_file.phpt:292562,292566,292571,292574,292716,293146,293152,293175-293176,293180,293216,293235,293253,293380,293400,293442,293447,293466,293487,293502,293538,293548,293558,293588,293590,293597,293627,293644,293653,293655,293699,293721,293726-293728,293730,293732,293735,293762,293768,293804,293815-293816,293862,293894,293896-293897,293901-293906,293917-293918,293965-293966,293976-293977,293985,293998,294040,294053,294075,294077-294078,294081,294089,294094,294100,294102,294104,294126-294127,294129,294164,294251-294253,294255,294259-294261,294265,294267,294269,294272,294278,294285,294302-294304,294307-294308,294310,294312-294313,294315,294317,294320-294323,294333-294336,294353,294418,294421,294487,294498,294532,294571,294695,294697,294724,294762,294814,294816,294825,294849,294854-294855
/php/php-src/trunk/tests/security/open_basedir_parse_ini_file.phpt:29815-29816,265951
+ /php/php-src/branches/PHP_5_3/tests/security/open_basedir_parse_ini_file.phpt:292562,292566,292571,292574,292620,292716,293146,293152,293175-293176,293180,293216,293235,293253,293380,293400,293442,293447,293466,293487,293502,293538,293548,293558,293588,293590,293597,293627,293644,293653,293655,293699,293721,293726-293728,293730,293732,293735,293762,293768,293804,293815-293816,293862,293894,293896-293897,293901-293906,293917-293918,293965-293966,293976-293977,293985,293998,294040,294053,294075,294077-294078,294081,294089,294094,294100,294102,294104,294126-294127,294129,294164,294251-294253,294255,294259-294261,294265,294267,294269,294272,294278,294285,294302-294304,294307-294308,294310,294312-294313,294315,294317,294320-294323,294333-294336,294353,294418,294421,294487,294498,294532,294571,294695,294697,294724,294762,294814,294816,294825,294849,294854-294855
/php/php-src/trunk/tests/security/open_basedir_parse_ini_file.phpt:29815-29816,265951
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php