summaryrefslogtreecommitdiff
path: root/libavcodec/alac.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/alac.c')
-rw-r--r--libavcodec/alac.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libavcodec/alac.c b/libavcodec/alac.c
index ffd2d77d7c..ada7c73c55 100644
--- a/libavcodec/alac.c
+++ b/libavcodec/alac.c
@@ -316,6 +316,11 @@ static int decode_element(AVCodecContext *avctx, AVFrame *frame, int ch_index,
int lpc_quant[2];
int rice_history_mult[2];
+ if (!alac->rice_limit) {
+ avpriv_request_sample(alac->avctx, "Compression with rice limit 0");
+ return AVERROR(ENOSYS);
+ }
+
decorr_shift = get_bits(&alac->gb, 8);
decorr_left_weight = get_bits(&alac->gb, 8);