z-engine
z-engine copied to clipboard
[Bug] Do not allow to throw PHP exceptions within FFI Zend callbacks
trafficstars
As throwing is restricted now in PHP, see https://github.com/php/php-src/pull/6366/commits/327e6c9d37dbb36c4a0097fcaabc9d58ecfe9323, I should either handle all exceptions from hooks internally with try..catch section silencing them or convert them to user fatal error with trigger_error(...,E_USER_ERROR).
Maybe there is some advanced technique to install custom exception handler for this, but I'm not aware about this.
Related to https://github.com/php/php-src/pull/6366