1
0
mirror of https://github.com/php/php-src.git synced 2026-04-21 23:18:13 +02:00
Files
archived-php-src/Zend/tests/try/bug70228_6.phpt
T

19 lines
275 B
PHP

--TEST--
Bug #70228 (memleak if return in finally block)
--FILE--
<?php
function test($x) {
foreach ($x as $v) {
try {
return str_repeat("a", 2);
} finally {
return 42;
}
}
}
var_dump(test([1]));
?>
--EXPECT--
int(42)