From: Marcus Boerger Date: Tue, 20 Feb 2007 13:07:53 +0000 (+0000) Subject: - Make stat based functions throw an exception X-Git-Tag: RELEASE_1_0_1~209 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1aa148e647035d356d5b12a727ae0db94acee17a;p=php - Make stat based functions throw an exception --- diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 5a62f6ea58..0bc40ab421 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -758,8 +758,10 @@ SPL_METHOD(SplFileInfo, func_name) \ { \ spl_filesystem_object *intern = (spl_filesystem_object*)zend_object_store_get_object(getThis() TSRMLS_CC); \ \ + php_set_error_handling(EH_THROW, spl_ce_RuntimeException TSRMLS_CC);\ spl_filesystem_object_get_file_name(intern TSRMLS_CC); \ php_u_stat(intern->file_name_type, intern->file_name, intern->file_name_len, func_num, FG(default_context), return_value TSRMLS_CC); \ + php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);\ } /* }}} */