Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Cadhalpun <andreas.cadhalpun@googlemail.com>2015-04-22 17:03:41 +0300
committerMichael Niedermayer <michaelni@gmx.at>2015-04-23 17:51:46 +0300
commit58d605ee9b3277289278dc40e022311f8e083833 (patch)
treef39b9109d7d8e2ed915760cea3d82498771226fd /libavcodec/alsdec.c
parentc82e870c12b263efe8c1b850c5c289bea6cb45a6 (diff)
alsdec: only adapt order for positive max_order
For max_order = 0 the clipping range is invalid. (amin = 2, amax = 1) Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/alsdec.c')
-rw-r--r--libavcodec/alsdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/alsdec.c b/libavcodec/alsdec.c
index e34cf6ef7c..75be55cc1e 100644
--- a/libavcodec/alsdec.c
+++ b/libavcodec/alsdec.c
@@ -682,7 +682,7 @@ static int read_var_block_data(ALSDecContext *ctx, ALSBlockData *bd)
if (!sconf->rlslms) {
- if (sconf->adapt_order) {
+ if (sconf->adapt_order && sconf->max_order) {
int opt_order_length = av_ceil_log2(av_clip((bd->block_length >> 3) - 1,
2, sconf->max_order + 1));
*bd->opt_order = get_bits(gb, opt_order_length);