#1038: Add workaround for PHP bug #47206
--------------------+-------------------------------------------------------
Reporter: david | Owner: david
Type: task | Status: assigned
Priority: normal | Milestone: 1.0
Component: config | Version: 1.0.0beta1
Severity: minor | Keywords:
Has_patch: 0 |
--------------------+-------------------------------------------------------
Changes (by david):
* status: new => assigned
Old description:
> {{{ext/xsl/xsltprocessor.c}}} has reflection API metadata since PHP 5.2.6
> (http://cvs.php.net/viewvc.cgi/php-
> src/ext/xsl/xsltprocessor.c?r1=1.39.2.2.2.11&r2=1.39.2.2.2.12).
>
> This metadata was incorrect in PHP 5.2.6, 5.2.7 and 5.2.8 in that it
> mandated the arguments for several methods to be {{{DOMDocument}}}s,
> while the XSL extension can also handle SimpleXML objects. This problem
> is fixed in 5.2.9.
>
> Our current subclass of {{{XSLTProcessor}}} has {{{DOMDocument}}} and
> {{{DOMNode}}} as argument type hints. This does not cause a problem on
> PHP < 5.2.6, as no arginfo existed at all in the PHP source code.
>
> What we need to do now is fix the method signatures to be compatible with
> 5.2.9+, and then add (don't cringe now) conditional
> {{{error_reporting()}}} calls that switch off {{{E_STRICT}}} and restore
> the old level afterwards before and after the {{{include()}}} call for
> {{{AgaviXmlConfigXsltProcessor}}} in
> {{{AgaviConfigCache::loadConfigHandlers()}}}
>
> Oh boy.
New description:
{{{ext/xsl/xsltprocessor.c}}} has reflection API metadata since PHP 5.2.6
(http://cvs.php.net/viewvc.cgi/php-
src/ext/xsl/xsltprocessor.c?r1=1.39.2.2.2.11&r2=1.39.2.2.2.12).
This metadata was incorrect in PHP 5.2.6, 5.2.7 and 5.2.8 in that it
mandated the arguments for several methods to be {{{DOMDocument}}}s, while
the XSL extension can also handle SimpleXML objects. This problem has been
fixed in 5.2.9 (http://bugs.php.net/bug.php?id=47206)
Our current subclass of {{{XSLTProcessor}}} has {{{DOMDocument}}} and
{{{DOMNode}}} as argument type hints. This does not cause a problem on PHP
< 5.2.6, as no arginfo existed at all in the PHP source code.
What we need to do now is fix the method signatures to be compatible with
5.2.9+, and then add (don't cringe now) conditional
{{{error_reporting()}}} calls that switch off {{{E_STRICT}}} and restore
the old level afterwards before and after the {{{include()}}} call for
{{{AgaviXmlConfigXsltProcessor}}} in
{{{AgaviConfigCache::loadConfigHandlers()}}}
Oh boy.
--
--
Ticket URL: <http://trac.agavi.org/ticket/1038#comment:1>
Agavi <http://www.agavi.org/>
An MVC Framework for PHP5
_______________________________________________
Agavi Tickets Mailing List
[email protected]
http://lists.agavi.org/mailman/listinfo/tickets