diff options
author | Greg Beaver <cellog@php.net> | 2003-12-18 17:48:54 +0000 |
---|---|---|
committer | Greg Beaver <cellog@php.net> | 2003-12-18 17:48:54 +0000 |
commit | b1362a53ab5e7249f993ba565a0984bfed32403a (patch) | |
tree | d506eabed846f610455b3c3b454936e3605fc141 /pear | |
parent | b766beaac9403457d7d4541770f663facb51dab5 (diff) | |
download | php-git-b1362a53ab5e7249f993ba565a0984bfed32403a.tar.gz |
remove retarded use of numbers (REALLY bad idea) for error handling, add check for E_STRICT and ignore all of those errors
Diffstat (limited to 'pear')
-rw-r--r-- | pear/scripts/pearcmd.php | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/pear/scripts/pearcmd.php b/pear/scripts/pearcmd.php index 338ed406c5..52723e0e3f 100644 --- a/pear/scripts/pearcmd.php +++ b/pear/scripts/pearcmd.php @@ -265,21 +265,21 @@ function cmdHelp($command) // }}} function error_handler($errno, $errmsg, $file, $line, $vars) { - if (error_reporting() == 0) { + if (error_reporting() == 0 || ($errno & E_STRICT)) { return; // @silenced error } $errortype = array ( - 1 => "Error", - 2 => "Warning", - 4 => "Parsing Error", - 8 => "Notice", - 16 => "Core Error", - 32 => "Core Warning", - 64 => "Compile Error", - 128 => "Compile Warning", - 256 => "User Error", - 512 => "User Warning", - 1024=> "User Notice" + E_ERROR => "Error", + E_WARNING => "Warning", + E_PARSE => "Parsing Error", + E_NOTICE => "Notice", + E_CORE_ERROR => "Core Error", + E_CORE_WARNING => "Core Warning", + E_COMPILE_ERROR => "Compile Error", + E_COMPILE_WARNING => "Compile Warning", + E_USER_ERROR => "User Error", + E_USER_WARNING => "User Warning", + E_USER_NOTICE => "User Notice" ); $prefix = $errortype[$errno]; $file = basename($file); |