Annotation of embedaddon/php/ext/xmlreader/tests/bug51936.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Bug #51936 (Crash with clone XMLReader)
! 3: --SKIPIF--
! 4: <?php
! 5: extension_loaded("xmlreader") or die("skip requires xmlreader");
! 6: ?>
! 7: --FILE--
! 8: <?php
! 9: echo "Test\n";
! 10:
! 11: $xmlreader = new XMLReader();
! 12: $xmlreader->xml("<a><b/></a>");
! 13:
! 14: $xmlreader->next();
! 15: $xmlreader2 = clone $xmlreader;
! 16: $xmlreader2->next();
! 17: ?>
! 18: Done
! 19: --EXPECTF--
! 20: Test
! 21:
! 22: Fatal error: Trying to clone an uncloneable object of class XMLReader in %s on line %d
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>