Commit 53915a8f authored by kostya's avatar kostya

Handle case of get_bits(0)

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@6365 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent d334d6a6
......@@ -142,7 +142,7 @@ static always_inline int get_tail(GetBitContext *gb, int k)
if(k<1 || k>65535)return 0;
p = av_log2_16bit(k);
e = (1 << (p + 1)) - k - 1;
res = get_bits(gb, p);
res = p ? get_bits(gb, p) : 0;
if(res >= e){
res = (res<<1) - e + get_bits1(gb);
}
......
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