summaryrefslogtreecommitdiff
path: root/libavcodec/wavpack.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/wavpack.c')
-rw-r--r--libavcodec/wavpack.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/wavpack.c b/libavcodec/wavpack.c
index d20556d312..b6022f0fa5 100644
--- a/libavcodec/wavpack.c
+++ b/libavcodec/wavpack.c
@@ -93,7 +93,7 @@ static av_always_inline int get_tail(GetBitContext *gb, int k)
return 0;
p = av_log2(k);
e = (1 << (p + 1)) - k - 1;
- res = p ? get_bits(gb, p) : 0;
+ res = get_bitsz(gb, p);
if (res >= e)
res = (res << 1) - e + get_bits1(gb);
return res;