[FFmpeg-cvslog] avcodec/mediacodecdec: fix return EAGAIN after EOF
Zhao Zhili
git at videolan.org
Wed Nov 22 09:39:37 EET 2023
ffmpeg | branch: master | Zhao Zhili <zhilizhao at tencent.com> | Sat Nov 18 16:03:11 2023 +0800| [f27fce0c0cc67ed2d36d7353d843234829bb2f5f] | committer: Zhao Zhili
avcodec/mediacodecdec: fix return EAGAIN after EOF
Signed-off-by: Zhao Zhili <zhilizhao at tencent.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f27fce0c0cc67ed2d36d7353d843234829bb2f5f
---
libavcodec/mediacodecdec_common.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libavcodec/mediacodecdec_common.c b/libavcodec/mediacodecdec_common.c
index 1151bb71f9..d6f91e6e89 100644
--- a/libavcodec/mediacodecdec_common.c
+++ b/libavcodec/mediacodecdec_common.c
@@ -804,6 +804,8 @@ int ff_mediacodec_dec_receive(AVCodecContext *avctx, MediaCodecDecContext *s,
return AVERROR_EXTERNAL;
}
+ if (s->draining && s->eos)
+ return AVERROR_EOF;
return AVERROR(EAGAIN);
}
More information about the ffmpeg-cvslog
mailing list