1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

golomb: Fix overread in get_ur_golomb_jpegls()

Fixes Ticket600

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Nir Ben David 2011-11-10 23:03:48 +01:00 committed by Michael Niedermayer
parent a14708d4ac
commit 083d9ba448

View File

@ -302,6 +302,8 @@ static inline int get_ur_golomb_jpegls(GetBitContext *gb, int k, int limit, int
}else{
int i;
for(i=0; SHOW_UBITS(re, gb, 1) == 0; i++){
if (get_bits_left(gb)<=0)
return -1;
LAST_SKIP_BITS(re, gb, 1);
UPDATE_CACHE(re, gb);
}