From: toby dot walsh at fxhome dot com Operating system: Linux PHP version: 5.2.10 PHP Bug Type: Unknown/Other Function Bug description: Errors are logged to syslog using LOG_NOTICE instead of LOG_ERR
Description: ------------ I'm using "error_log = syslog" in my php.ini to log all errors to syslog. But the errors end up being logged using the LOG_NOTICE log level instead of the LOG_ERR level. I've traced this back to the internal php_log_err function in main/main.c which uses php_syslog(LOG_NOTICE, "%.500s", log_message); when it should probably be using php_syslog(LOG_ERR, "%.500s", log_message); Reproduce code: --------------- Set the following directives in php.ini error_reporting = E_ALL & ~E_NOTICE log_errors = On error_log = syslog Then generate a syntax error with something like <?php test( ?> Expected result: ---------------- An error message should be logged to syslog with a log level of LOG_ERR Actual result: -------------- The error message is logged, but using a log level of LOG_NOTICE instead of LOG_ERR -- Edit bug report at http://bugs.php.net/?id=49467&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=49467&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=49467&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=49467&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=49467&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=49467&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=49467&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=49467&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=49467&r=needscript Try newer version: http://bugs.php.net/fix.php?id=49467&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=49467&r=support Expected behavior: http://bugs.php.net/fix.php?id=49467&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=49467&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=49467&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=49467&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=49467&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=49467&r=dst IIS Stability: http://bugs.php.net/fix.php?id=49467&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=49467&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=49467&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=49467&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=49467&r=mysqlcfg