> On Apr 26, 2022, at 4:20 PM, Zhao Zhili <quinkbl...@foxmail.com> wrote:
>
> ---
> libavformat/mov.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/libavformat/mov.c b/libavformat/mov.c
> index e948c6cd0f..429f9fcbf7 100644
> --- a/libavformat/mov.c
> +++ b/libavformat/mov.c
> @@ -7691,10 +7691,12 @@ static int mov_read_default(MOVContext *c,
> AVIOContext *pb, MOVAtom atom)
>
> if (atom.size < 0)
> atom.size = INT64_MAX;
> - while (total_size <= atom.size - 8 && !avio_feof(pb)) {
> + while (total_size <= atom.size - 8) {
> int (*parse)(MOVContext*, AVIOContext*, MOVAtom) = NULL;
> a.size = avio_rb32(pb);
> a.type = avio_rl32(pb);
> + if (avio_feof(pb))
> + break;
> if (((a.type == MKTAG('f','r','e','e') && c->moov_retry) ||
> a.type == MKTAG('h','o','o','v')) &&
> a.size >= 8 &&
> --
Applied.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".