diff options
Diffstat (limited to 'libavcodec/wavpack.c')
-rw-r--r-- | libavcodec/wavpack.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/wavpack.c b/libavcodec/wavpack.c index 4a4a5847e9..558e57d40e 100644 --- a/libavcodec/wavpack.c +++ b/libavcodec/wavpack.c @@ -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); } |