mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-25 04:30:02 +00:00
qpeg: Fix out of array writes.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
aaa1173de7
commit
4299dfa5de
@ -203,6 +203,8 @@ static void qpeg_decode_inter(const uint8_t *src, uint8_t *dst, int size,
|
||||
filled = 0;
|
||||
dst -= stride;
|
||||
height--;
|
||||
if(height < 0)
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else if(code >= 0xC0) { /* copy code: 0xC0..0xDF */
|
||||
@ -214,6 +216,8 @@ static void qpeg_decode_inter(const uint8_t *src, uint8_t *dst, int size,
|
||||
filled = 0;
|
||||
dst -= stride;
|
||||
height--;
|
||||
if(height < 0)
|
||||
break;
|
||||
}
|
||||
}
|
||||
size -= code + 1;
|
||||
|
Loading…
Reference in New Issue
Block a user