mirror of
https://github.com/php/php-src.git
synced 2024-10-19 15:34:25 +00:00
34 lines
689 B
Plaintext
34 lines
689 B
Plaintext
|
--TEST--
|
||
|
Bug #26384 (domxslt->process causes segfault with xsl:key)
|
||
|
--SKIPIF--
|
||
|
<?php require_once('skipif.inc'); ?>
|
||
|
--FILE--
|
||
|
<?php
|
||
|
$dom = new domDocument;
|
||
|
$dom->load(dirname(__FILE__)."/area_name.xml");
|
||
|
if(!$dom) {
|
||
|
echo "Error while parsing the document\n";
|
||
|
exit;
|
||
|
}
|
||
|
$xsl = new domDocument;
|
||
|
$xsl->load(dirname(__FILE__)."/area_list.xsl");
|
||
|
if(!$xsl) {
|
||
|
echo "Error while parsing the document\n";
|
||
|
exit;
|
||
|
}
|
||
|
$proc = new xsltprocessor;
|
||
|
if(!$proc) {
|
||
|
echo "Error while making xsltprocessor object\n";
|
||
|
exit;
|
||
|
}
|
||
|
|
||
|
$proc->importStylesheet($xsl);
|
||
|
print $proc->transformToXml($dom);
|
||
|
|
||
|
//this segfaulted before
|
||
|
print $dom->documentElement->firstChild->nextSibling->nodeName;
|
||
|
|
||
|
--EXPECT--
|
||
|
HERE
|
||
|
ROW
|