copyright update
[squirrelmail.git] / class / error.class.php
index acd1abdc7832297f188d41acfde20c7e83ae5dc2..cef939bdad5f3b0875d93753ab16387822c8d51d 100644 (file)
@@ -1,12 +1,12 @@
 <?php
 <?php
+
 /**
  * error.class.php
  *
 /**
  * error.class.php
  *
- * Copyright (c) 2005 The SquirrelMail Project Team
- * Licensed under the GNU GPL. For full terms see the file COPYING.
- *
  * This contains the custom error handler for SquirrelMail.
  *
  * This contains the custom error handler for SquirrelMail.
  *
+ * @copyright &copy; 2005-2006 The SquirrelMail Project Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
  * @version $Id$
  * @package squirrelmail
  */
  * @version $Id$
  * @package squirrelmail
  */
@@ -73,8 +73,8 @@ class ErrorHandler {
         /**
          * Get current error reporting level.
          *
         /**
          * Get current error reporting level.
          *
-         * PHP 4.1.2 does not return current error reporting level in ini_get (php 5.1b3 and 
-         * 4.3.10 does). Retrieve current error reporting level while setting error reporting 
+         * PHP 4.1.2 does not return current error reporting level in ini_get (php 5.1b3 and
+         * 4.3.10 does). Retrieve current error reporting level while setting error reporting
          * to ini value and reset it to retrieved value.
          */
         $iCurErrLevel = error_reporting(ini_get('error_reporting'));
          * to ini value and reset it to retrieved value.
          */
         $iCurErrLevel = error_reporting(ini_get('error_reporting'));
@@ -86,7 +86,7 @@ class ErrorHandler {
          * (sq_mb_list_encodings(), ldap function calls in functions/abook_ldap_server.php)
          * handle errors themselves and @ is used to disable generic php error messages.
          */
          * (sq_mb_list_encodings(), ldap function calls in functions/abook_ldap_server.php)
          * handle errors themselves and @ is used to disable generic php error messages.
          */
-        if ((bool) $iCurErrLevel) {
+        if ($iErrNo & $iCurErrLevel) {
             /*
              * The following errors cannot be handled by a user defined error handler:
              * E_ERROR, E_PARSE, E_CORE_ERROR, E_CORE_WARNING, E_COMPILE_ERROR, E_COMPILE_WARNING
             /*
              * The following errors cannot be handled by a user defined error handler:
              * E_ERROR, E_PARSE, E_CORE_ERROR, E_CORE_WARNING, E_COMPILE_ERROR, E_COMPILE_WARNING