Bug #17932 Updated: No way to determine @ operator usage from within custom errors handler
| From: | derick@php.net | Date: | Sun, 23 Jun 2002 10:46:07 +0000 |
| Subject: | Bug #17932 Updated: No way to determine @ operator usage from within custom errors handler | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-11836@lists.php.net to get a copy of this message | ||
ID: 17932
Updated by: derick@php.net
Reported By: flying@dom.natm.ru
-Status: Closed
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: Windows 2000
PHP Version: 4.2.1
New Comment:
User error -> Bogus
Previous Comments:
------------------------------------------------------------------------
[2002-06-23 06:23:08] flying@dom.natm.ru
Hmm... It looks like my previous tests have some other problems.
error_reporting() function works fine together with @ operator.
Sorry for bothering...
------------------------------------------------------------------------
[2002-06-23 05:45:05] derick@php.net
Can you please provide a full, self-contained script that shows this
problem?
Derick
------------------------------------------------------------------------
[2002-06-23 05:41:18] flying@dom.natm.ru
There is currently no way for custom error handler function to
determine, if expression which generate any particular error was called
using @ operator or not.
For example there will be no difference between:
$fp = fopen('unavailable_file','r');
and
$fp = @fopen('unavailable_file','r');
Warning will be thrown in both cases, while it must be only thrown
into first case, as requested by programmer. So there must be some way
to distinguish these cases.
Normally error_reporting() function should return 0, being called from
custom error handler in a case, when @ operator was used, but it
returns error reporting level, which is by default. I think it is wrong
behaviour and it should be improved in a way, described before.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17932&edit=1