sanm: remove "duplicate" for loop.
Fixes input buffer overread Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
49b729d3af
commit
1bb05797ec
@ -652,8 +652,7 @@ static int old_codec47(SANMVideoContext *ctx, int top,
|
|||||||
if (bytestream2_get_bytes_left(&ctx->gb) < width * height)
|
if (bytestream2_get_bytes_left(&ctx->gb) < width * height)
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
for (j = 0; j < height; j++) {
|
for (j = 0; j < height; j++) {
|
||||||
for (i = 0; i < width; i++)
|
bytestream2_get_bufferu(&ctx->gb, dst, width);
|
||||||
bytestream2_get_bufferu(&ctx->gb, dst, width);
|
|
||||||
dst += stride;
|
dst += stride;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user