mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2026-06-16 04:32:47 +02:00
avcodec/sanm: reject codec37 frames taller than the allocated buffer
No testcase Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
committed by
michaelni
parent
b2695bcbb3
commit
ab5043f055
@@ -1241,6 +1241,9 @@ static int old_codec37(SANMVideoContext *ctx, GetByteContext *gb, int top, int l
|
||||
if (width > ctx->aligned_width)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
if (FFALIGN(height, 4) > ctx->aligned_height)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
if (bytestream2_get_bytes_left(gb) < 16)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user