From: Florent Bruneau Date: Sun, 28 Oct 2007 12:29:15 +0000 (+0100) Subject: Fix an error in error_handler making debug a bit harder X-Git-Tag: xorg/0.9.16~254 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=d70b66390400f3538713fa307c69b3000ed1fc1a;p=platal.git Fix an error in error_handler making debug a bit harder Signed-off-by: Florent Bruneau --- diff --git a/include/platal.inc.php b/include/platal.inc.php index ad6bbe9..83833e5 100644 --- a/include/platal.inc.php +++ b/include/platal.inc.php @@ -74,7 +74,8 @@ function pl_error_handler($errno, $errstr, $errfile, $errline) E_USER_ERROR => "User Error", E_USER_WARNING => "User Warning", E_USER_NOTICE => "User Notice", - E_STRICT => "Runtime Notice" + E_STRICT => "Runtime Notice", + E_RECOVERABLE_ERROR => "Recoverable Error" ); } @@ -85,10 +86,11 @@ function pl_error_handler($errno, $errstr, $errfile, $errline) } } + $type = isset($errortype[$errno]) ? $errortype[$errno] : $errno; $errstr = utf8_encode(htmlentities($errstr)); $GLOBALS['pl_errors'][] = "
". - "{$errortype[$errno]} $errstr
". + "{$type} $errstr
". "$errfile : $errline". "
"; }