Hello,
I think it is not possible to handle php fatal errors with exceptions
or set_error_handler.
The only way I found is to patch the ffmpeg-php code to raise only a
php warning.
By looking the ffmpeg-php code I saw that this is the only exception
of the ffmpeg_movie object that is raised as a php error
I guess that's an oversight because I do not see any interest to block
the execution of the php script on this specific error.
My patch :
#######################################################
--- ffmpeg_movie.c 2009-03-02 08:49:37.000000000 +0100
+++ ffmpeg_movie.c 2009-03-02 08:50:17.000000000 +0100
@@ -501,7 +501,7 @@ static AVCodecContext* _php_get_decoder_
codec_id));
-
if (!decoder) {
- zend_error(E_ERROR, "Could not find decoder for %s",-
+ zend_error(E_WARNING, "Could not find decoder for %s",-
_php_get_filename(ffmovie_ctx));
return NULL;
}
#######################################################