Ask a Question related to PHP Bugs, Design and Development.
-
quintenbernaert at gmail dot com #1
#40682 [NEW]: set_error_handler doesn't respect @ operator
From: quintenbernaert at gmail dot com
Operating system: Linux
PHP version: 4.4.6
PHP Bug Type: Scripting Engine problem
Bug description: set_error_handler doesn't respect @ operator
Description:
------------
set_error_handler doesn't respect the @ operator and it should respect it.
The @ does ignore errors of that function. set_error_handler report errors.
But if I put an @ before a function, set_error_handler still show the error
and it shouldn't show it.
Reproduce code:
---------------
<?php
function errors($errno, $errstr, $errfile, $errline)
{
echo 'Error handler<br /><br />
'.$errno.'<br />
'.$errstr.'<br />
'.$errfile.'<br />
'.$errline.'<br />';
}
set_error_handler("errors");
@getimagesize();
?>
Expected result:
----------------
Empty page.
Actual result:
--------------
Error handler
2
Wrong parameter count for getimagesize()
/home/quinten/www/problem_errorhandler.php
14
--
Edit bug report at [url]http://bugs.php.net/?id=40682&edit=1[/url]
--
Try a CVS snapshot (PHP 4.4): [url]http://bugs.php.net/fix.php?id=40682&r=trysnapshot44[/url]
Try a CVS snapshot (PHP 5.2): [url]http://bugs.php.net/fix.php?id=40682&r=trysnapshot52[/url]
Try a CVS snapshot (PHP 6.0): [url]http://bugs.php.net/fix.php?id=40682&r=trysnapshot60[/url]
Fixed in CVS: [url]http://bugs.php.net/fix.php?id=40682&r=fixedcvs[/url]
Fixed in release: [url]http://bugs.php.net/fix.php?id=40682&r=alreadyfixed[/url]
Need backtrace: [url]http://bugs.php.net/fix.php?id=40682&r=needtrace[/url]
Need Reproduce Script: [url]http://bugs.php.net/fix.php?id=40682&r=needscript[/url]
Try newer version: [url]http://bugs.php.net/fix.php?id=40682&r=oldversion[/url]
Not developer issue: [url]http://bugs.php.net/fix.php?id=40682&r=support[/url]
Expected behavior: [url]http://bugs.php.net/fix.php?id=40682&r=notwrong[/url]
Not enough info: [url]http://bugs.php.net/fix.php?id=40682&r=notenoughinfo[/url]
Submitted twice: [url]http://bugs.php.net/fix.php?id=40682&r=submittedtwice[/url]
register_globals: [url]http://bugs.php.net/fix.php?id=40682&r=globals[/url]
PHP 3 support discontinued: [url]http://bugs.php.net/fix.php?id=40682&r=php3[/url]
Daylight Savings: [url]http://bugs.php.net/fix.php?id=40682&r=dst[/url]
IIS Stability: [url]http://bugs.php.net/fix.php?id=40682&r=isapi[/url]
Install GNU Sed: [url]http://bugs.php.net/fix.php?id=40682&r=gnused[/url]
Floating point limitations: [url]http://bugs.php.net/fix.php?id=40682&r=float[/url]
No Zend Extensions: [url]http://bugs.php.net/fix.php?id=40682&r=nozend[/url]
MySQL Configuration Error: [url]http://bugs.php.net/fix.php?id=40682&r=mysqlcfg[/url]
quintenbernaert at gmail dot com Guest
-
#40684 [NEW]: about set_error_handler bug
From: dq2 at compass dot jp Operating system: windowsxp PHP version: 4.4.6 PHP Bug Type: *General Issues Bug description: ... -
what's better: yon or removefromworld with respect toprocessing power
hello; any model that is beyond yon does not get rendered; and any model that has been removefromworld() does not get rendered; are there any... -
#25887 [NEW]: session.save_path should respect open_basedir
From: john at scl dot co dot uk Operating system: linux PHP version: 4.3.3 PHP Bug Type: Feature/Change Request Bug... -
set_error_handler() and @ error control operator
Hi. I mentioned this before, but I think my question got kind of lost. I'll make it one short question now. With... -
Finder windows don't respect the dock, hard drive keeps moving
I have an original eMac with jaguar and updates current to about a week ago. I've had the continuing problem of the finder opening windows that... -
tony2001@php.net #2
#40682 [Opn->Bgs]: set_error_handler doesn't respect @ operator
ID: 40682
Updated by: [email]tony2001@php.net[/email]
Reported By: quintenbernaert at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: Linux
PHP Version: 4.4.6
New Comment:
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
[url]http://www.php.net/manual/[/url] and the instructions on how to report
a bug at [url]http://bugs.php.net/how-to-report.php[/url]
Previous Comments:
------------------------------------------------------------------------
[2007-03-01 16:59:03] quintenbernaert at gmail dot com
Description:
------------
set_error_handler doesn't respect the @ operator and it should respect
it. The @ does ignore errors of that function. set_error_handler report
errors. But if I put an @ before a function, set_error_handler still
show the error and it shouldn't show it.
Reproduce code:
---------------
<?php
function errors($errno, $errstr, $errfile, $errline)
{
echo 'Error handler<br /><br />
'.$errno.'<br />
'.$errstr.'<br />
'.$errfile.'<br />
'.$errline.'<br />';
}
set_error_handler("errors");
@getimagesize();
?>
Expected result:
----------------
Empty page.
Actual result:
--------------
Error handler
2
Wrong parameter count for getimagesize()
/home/quinten/www/problem_errorhandler.php
14
------------------------------------------------------------------------
--
Edit this bug report at [url]http://bugs.php.net/?id=40682&edit=1[/url]
tony2001@php.net Guest



Reply With Quote

