ID:               38134
 Updated by:       [EMAIL PROTECTED]
 Reported By:      gerome dot fournier at infomaniak dot ch
 Status:           Feedback
 Bug Type:         XSLT related
 Operating System: Debian Sarge
 PHP Version:      4.4.2
 New Comment:

What is the version of Sablotron used?
Are you able to get a decent GDB backtrace (using PHP configured with
--enable-debug)?
What was your full configure line?

It works just fine here with 1.0.1 & Linux i386.


Previous Comments:
------------------------------------------------------------------------

[2006-08-17 09:48:45] gabriel dot zerbib at protilab dot com

I'm sorry Tony, you were a little bit quick in closing with "can't
reproduce".

You can just try the online demo. You'll manage to achieve the 100
iterations for some time, but if you hit Refresh a few times, you sure
will run into the problem: the page will not come to you, your browser
will report some proxy error or some "Host not found" error, which is
in fact caused by a violent crash of the PHP script and PHP
interpreter, never returning a response to your browser.

Please do not close this bug report too fast, as sample data were
properly provided, and the target platform and system and version.

Thanks.

------------------------------------------------------------------------

[2006-08-17 09:43:05] [EMAIL PROTECTED]

Can't reproduce.

------------------------------------------------------------------------

[2006-08-17 09:42:11] gerome dot fournier at infomaniak dot ch

Re-opened as the owner of the web site provided new feedbacks.

------------------------------------------------------------------------

[2006-08-17 09:22:12] gabriel dot zerbib at protilab dot com

TEST DATA:

The files can be found at:
http://www.protilab.com/test/sample.xml
http://www.protilab.com/test/sample.xsl

And the PHP script can be run online at:
http://www.protilab.com/test/sample.php


SCENARIO:
An XSLT processor is instanciated using the XML and XSL files specified
in the arguments, in a loop of 100 iterations.
Among these 100 iterations, a seg-fault is likely to happen.



XML file to process (sample.xml):
---------------------------------------------------
<?xml version="1.0" encoding="iso-8859-1"?>
<?xml-stylesheet type="text/xsl" href="sample.xsl"?>

<root>
        <node1 id="foo">
                <subnodeA>Some Data A</subnodeA>
                <subnodeA attr="123">Some Mode Data A</subnodeA>
        </node1>
        <node1 id="bar">
                <subnodeA>Some Data A in another node</subnodeA>
                <subnodeA attr="345">Some Mode Data in second node</subnodeA>
        </node1>
</root>
---------------------------------------------------


XSL file to apply (sample.xsl):
---------------------------------------------------
<?xml version="1.0" encoding="iso-8859-1"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>

        <xsl:template match="/">
                <html>
                        <head>
                                <title>Title here</title>
                        </head>

                        <body>
                                <xsl:for-each select="/root/node1">
                                        <xsl:value-of select="@id"/>
                                        <ul>
                                                <xsl:for-each select="subnodeA">
                                                        <li><xsl:value-of 
select="text()"/> <xsl:if test="@attr"> (
<xsl:value-of select="@attr"/> ) </xsl:if> </li> 
                                                </xsl:for-each>
                                        </ul>
                                </xsl:for-each>
                        </body> 
                </html>
        </xsl:template>

</xsl:stylesheet>
---------------------------------------------------


PHP script (sample.php)
---------------------------------------------------
<?
$xmlFile = 'sample.xml';
$xsl_url = 'sample.xsl';


for($i = 0; $i < 100; ++$i)
{

        $xh = xslt_create();
        xslt_set_encoding($xh, 'iso-8859-1');
        xslt_process($xh, $xmlFile, $xsl_url, 'result.html');
        xslt_free($xh);
        
        echo("iteration: $i = OK <br/>\n");

}
?>
---------------------------------------------------

------------------------------------------------------------------------

[2006-07-26 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/38134

-- 
Edit this bug report at http://bugs.php.net/?id=38134&edit=1

Reply via email to