this fixes AV_CODEC_CAP_DELAY encoders going into FATAL error and exiting on quit or finish encoding once they go into draining mode and send_frame() returns AVERROR_EOF
Signed-off-by: Jason Stevens <j...@wizardofthenet.com> --- fftools/ffmpeg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c index da4259a9a8..f30ed946c0 100644 --- a/fftools/ffmpeg.c +++ b/fftools/ffmpeg.c @@ -1939,7 +1939,7 @@ static void flush_encoders(void) while ((ret = avcodec_receive_packet(enc, &pkt)) == AVERROR(EAGAIN)) { ret = avcodec_send_frame(enc, NULL); - if (ret < 0) { + if (ret < 0 && ret != AVERROR_EOF) { av_log(NULL, AV_LOG_FATAL, "%s encoding failed: %s\n", desc, av_err2str(ret)); -- 2.19.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel