Skip to content

Commit 04da32d

Browse files
committed
Also check $errno against PHP's error_reporting.
This is necessary to make sure that if a minimum PHP error level has been set, this is also respected by SSP's error handler. Most notably, this will make calls prefixed with '@', the PHP warning silencer, actually silence the warnings. The SSP code tries to makes use of the @ sign on various places around the code, but this will only work if it's actually checked here.
1 parent 631e45e commit 04da32d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

www/_include.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ function SimpleSAML_error_handler($errno, $errstr, $errfile = NULL, $errline = 0
5454
}
5555

5656

57-
if ($errno & SimpleSAML_Utilities::$logMask) {
57+
if ($errno & SimpleSAML_Utilities::$logMask || ! ($errno & error_reporting() )) {
5858
/* Masked error. */
5959
return FALSE;
6060
}

0 commit comments

Comments
 (0)