ffmpeg | branch: master | Andreas Rheinhardt <[email protected]> | Wed Dec 8 15:04:25 2021 +0100| [b9f5a26a39efc0e49e2296306efde572630b1796] | committer: Andreas Rheinhardt
avcodec/movtextdec: Improve size check Reviewed-by: Philip Langdale <[email protected]> Signed-off-by: Andreas Rheinhardt <[email protected]> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b9f5a26a39efc0e49e2296306efde572630b1796 --- libavcodec/movtextdec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavcodec/movtextdec.c b/libavcodec/movtextdec.c index 8dd571d64c..5083308d58 100644 --- a/libavcodec/movtextdec.c +++ b/libavcodec/movtextdec.c @@ -537,8 +537,8 @@ static int mov_text_decode_frame(AVCodecContext *avctx, m->size_var = 8; //size_var is equal to 8 or 16 depending on the size of box - if (tsmb_size == 0) { - av_log(avctx, AV_LOG_ERROR, "tsmb_size is 0\n"); + if (tsmb_size < m->size_var) { + av_log(avctx, AV_LOG_ERROR, "tsmb_size invalid\n"); return AVERROR_INVALIDDATA; } _______________________________________________ ffmpeg-cvslog mailing list [email protected] https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
