Commit 7e9e1b70 authored by Sasi Inguva's avatar Sasi Inguva Committed by Philip Langdale

lavc/movtextdec.c: Avoid infinite loop on invalid data.

Signed-off-by: 's avatarSasi Inguva <isasi@google.com>
parent 92de2c23
......@@ -471,6 +471,10 @@ static int mov_text_decode_frame(AVCodecContext *avctx,
tsmb_type = AV_RB32(tsmb);
tsmb += 4;
if (tsmb_size == 0) {
return AVERROR_INVALIDDATA;
}
if (tsmb_size == 1) {
if (m->tracksize + 16 > avpkt->size)
break;
......
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