Commit 18be3fac authored by Marton Balint's avatar Marton Balint

ffplay: check for filter EOF return codes

Fixes ticket #2800.
Signed-off-by: 's avatarMarton Balint <cus@passwd.hu>
parent e84ca8d3
...@@ -1956,6 +1956,8 @@ static int video_thread(void *arg) ...@@ -1956,6 +1956,8 @@ static int video_thread(void *arg)
ret = av_buffersink_get_frame_flags(filt_out, frame, 0); ret = av_buffersink_get_frame_flags(filt_out, frame, 0);
if (ret < 0) { if (ret < 0) {
if (ret == AVERROR_EOF)
is->video_finished = serial;
ret = 0; ret = 0;
break; break;
} }
...@@ -2236,6 +2238,8 @@ static int audio_decode_frame(VideoState *is) ...@@ -2236,6 +2238,8 @@ static int audio_decode_frame(VideoState *is)
is->audio_buf_frames_pending = 0; is->audio_buf_frames_pending = 0;
continue; continue;
} }
if (ret == AVERROR_EOF)
is->audio_finished = is->audio_pkt_temp_serial;
return ret; return ret;
} }
is->audio_buf_frames_pending = 1; is->audio_buf_frames_pending = 1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment