From 740c14dbd788c1a3c49bea3af0af87b5f8077933 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Tue, 16 Sep 2008 01:24:12 +0000 Subject: [PATCH] Fix regression test failure caused by golomb limit not being considered in r15334. Originally committed as revision 15338 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/golomb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/golomb.h b/libavcodec/golomb.h index f2fb8928a2..627fcdc40f 100644 --- a/libavcodec/golomb.h +++ b/libavcodec/golomb.h @@ -255,7 +255,7 @@ static inline int get_ur_golomb_jpegls(GetBitContext *gb, int k, int limit, int log= av_log2(buf); - if(log - k >= 32-MIN_CACHE_BITS){ + if(log - k >= 32-MIN_CACHE_BITS && 32-log < limit){ buf >>= log - k; buf += (30-log)<