Commit 7cb46b51 authored by Michael Niedermayer's avatar Michael Niedermayer

targa: use checked bytestream read

Fix out of array read

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 2b12d1ff
...@@ -267,7 +267,7 @@ static int decode_frame(AVCodecContext *avctx, ...@@ -267,7 +267,7 @@ static int decode_frame(AVCodecContext *avctx,
line = dst; line = dst;
y = 0; y = 0;
do { do {
bytestream2_get_bufferu(&s->gb, line, img_size); bytestream2_get_buffer(&s->gb, line, img_size);
line = advance_line(dst, line, stride, &y, h, interleave); line = advance_line(dst, line, stride, &y, h, interleave);
} while (line); } while (line);
} }
......
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