cvs: php-src /tests/lang bug26866.phpt
| From: | Jani Taskinen | Date: | Tue, 10 Feb 2004 12:58:37 +0000 |
| Subject: | cvs: php-src /tests/lang bug26866.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-26080@lists.php.net to get a copy of this message | ||
sniper Tue Feb 10 07:58:37 2004 EDT
Added files:
/php-src/tests/lang bug26866.phpt
Log:
Add test case for bug #26866
http://cvs.php.net/co.php/php-src/tests/lang/bug26866.phpt?r=1.1&p=1
Index: php-src/tests/lang/bug26866.phpt
+++ php-src/tests/lang/bug26866.phpt
--TEST--
Bug #26866 (segfault when exception raised in __get)
--FILE--
<?php
class bar {
function get_name() {
return 'bar';
}
}
class foo {
function __get($sName) {
throw new Exception('Exception!');
return new bar();
}
}
$foo = new foo();
try {
echo $foo->bar->get_name();
}
catch (Exception $E) {
echo "Exception raised!\n";
}
?>
--EXPECT--
Exception raised!