Commit 7b7f47e7 authored by Justin Ruggles's avatar Justin Ruggles

imc: validate channel count

ask for a sample if not mono
parent 95fee70d
...@@ -108,6 +108,11 @@ static av_cold int imc_decode_init(AVCodecContext * avctx) ...@@ -108,6 +108,11 @@ static av_cold int imc_decode_init(AVCodecContext * avctx)
IMCContext *q = avctx->priv_data; IMCContext *q = avctx->priv_data;
double r1, r2; double r1, r2;
if (avctx->channels != 1) {
av_log_ask_for_sample(avctx, "Number of channels is not supported\n");
return AVERROR_PATCHWELCOME;
}
q->decoder_reset = 1; q->decoder_reset = 1;
for(i = 0; i < BANDS; i++) for(i = 0; i < BANDS; i++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment