Steps to reproduce the issue
1) enable error logging in PHP with log_errors=on in php.ini
2) create a fatal error in a component, for example a spelling mistake
3) open a page that loads the component
Expected result
Fatal error logged to the server's error log.
Actual result
No message in the server log, brief error displayed in browser only.
System information (as much as possible)
Joomla 3.5.0, PHP 7.0
Additional comments
I think the changes introduced by #9270 have caused this. I have temporarily fixed this locally by adding the following to doErrorHandling() in plugins/system/redirect/redirect.php:
if (ini_get('log_errors'))
error_log('PHP Fatal error: '.$error->getMessage().' in '.$error->getFile().' on line '.$error->getLine());
It depends on the type of error being thrown. PHP 7 replaced some fatal errors with a new Error object and that and the Exception class now implement a Throwable interface which any exception handler set by
set_exception_handler()
will catch. See http://php.net/manual/en/class.error.php and the sidebar there which lists all of the new Error objects.