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 599e36ccc5..ab9dec9859 100644
--- a/libavcodec/wavpack.c
+++ b/libavcodec/wavpack.c
@@ -248,7 +248,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;