You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
mtvdec: check that the buf is large enough for probing
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -57,7 +57,7 @@ static int mtv_probe(AVProbeData *p)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
/* Check for nonzero in bpp and (width|height) header fields */
|
/* Check for nonzero in bpp and (width|height) header fields */
|
||||||
if(!(p->buf[51] && AV_RL16(&p->buf[52]) | AV_RL16(&p->buf[54])))
|
if(p->buf_size < 57 || !(p->buf[51] && AV_RL16(&p->buf[52]) | AV_RL16(&p->buf[54])))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
/* If width or height are 0 then imagesize header field should not */
|
/* If width or height are 0 then imagesize header field should not */
|
||||||
|
Reference in New Issue
Block a user