mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-28 20:53:54 +02:00
targa: Fix input buffer size check.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
8f0d9b43be
commit
43fd321252
@ -229,7 +229,7 @@ static int decode_frame(AVCodecContext *avctx,
|
||||
buf += res;
|
||||
}else{
|
||||
size_t img_size = s->width * ((s->bpp + 1) >> 3);
|
||||
CHECK_BUFFER_SIZE(buf, buf_end, img_size, "image data");
|
||||
CHECK_BUFFER_SIZE(buf, buf_end, img_size * s->height , "image data");
|
||||
for(y = 0; y < s->height; y++){
|
||||
memcpy(dst, buf, img_size);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user