aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2011-05-20 00:59:47 +0200
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2011-05-25 12:42:18 +0200
commit6b5e1825406a8180c72863bf63964ae50a8499db (patch)
treead4d31206b53a47d2e8f944a1ee4415fc08e47fb
parent48df6a241532f0702fc4fd10ddcbfac435e4027c (diff)
downloadffmpeg-6b5e1825406a8180c72863bf63964ae50a8499db.tar.gz
ffmpeg: handle the case when get_filtered_frame() fails
-rw-r--r--ffmpeg.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index af57fc9456..7f7e060856 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1692,7 +1692,8 @@ static int output_packet(AVInputStream *ist, int ist_index,
while (frame_available) {
AVRational ist_pts_tb;
if (ist->st->codec->codec_type == AVMEDIA_TYPE_VIDEO && ost->output_video_filter)
- get_filtered_video_frame(ost->output_video_filter, &picture, &ost->picref, &ist_pts_tb);
+ if (get_filtered_video_frame(ost->output_video_filter, &picture, &ost->picref, &ist_pts_tb) < 0)
+ goto cont;
if (ost->picref)
ist->pts = av_rescale_q(ost->picref->pts, ist_pts_tb, AV_TIME_BASE_Q);
#endif