php-src/Zend/tests/bug38234.phpt
2012-10-10 10:27:49 +08:00

19 lines
236 B
PHP

--TEST--
Bug #38234 (Exception in __clone makes memory leak)
--FILE--
<?php
class Foo {
function __clone() {
throw new Exception();
}
}
try {
$x = new Foo();
$y = clone $x;
} catch (Exception $e) {
}
echo "ok\n";
?>
--EXPECT--
ok