summaryrefslogtreecommitdiff
path: root/libavcodec/dcaenc.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/dcaenc.c')
-rw-r--r--libavcodec/dcaenc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libavcodec/dcaenc.c b/libavcodec/dcaenc.c
index 2b61bec98c..eccff08c03 100644
--- a/libavcodec/dcaenc.c
+++ b/libavcodec/dcaenc.c
@@ -365,8 +365,7 @@ static inline uint32_t quantize(int32_t sample, int bits)
{
av_assert0(sample < 1 << (bits - 1));
av_assert0(sample >= -(1 << (bits - 1)));
- sample &= sample & ((1 << bits) - 1);
- return sample;
+ return sample & ((1 << bits) - 1);
}
static inline int find_scale_factor7(int64_t max_value, int bits)