xref: /PHP-8.2/ext/dom/tests/bug69373.phpt (revision bd9f4fa6)
1--TEST--
2Bug #69373 References to deleted XPath query results
3--EXTENSIONS--
4dom
5--FILE--
6<?php
7$doc = new DOMDocument();
8for( $i=0; $i<20; $i++ ) {
9    $doc->loadXML("<parent><child /><child /></parent>");
10    $xpath = new DOMXpath($doc);
11    $all = $xpath->query('//*');
12    $doc->firstChild->nodeValue = '';
13}
14echo 'DONE', PHP_EOL;
15?>
16--EXPECT--
17DONE
18