aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorJustin Ruggles <justin.ruggles@gmail.com>2012-10-22 15:54:29 -0400
committerJustin Ruggles <justin.ruggles@gmail.com>2012-11-01 11:29:17 -0400
commit1c7a0161538a9e8417086759a5d6d3295337c433 (patch)
treeff73563e2fa6845308cad3bfd4b5feb22802b787 /libavcodec
parent32c7769e5c851ff7b47a83113b97a325dde7b442 (diff)
downloadffmpeg-1c7a0161538a9e8417086759a5d6d3295337c433.tar.gz
imc: set channels to 1 instead of validating it
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/imc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/imc.c b/libavcodec/imc.c
index 1156e8aac2..4c2d01d025 100644
--- a/libavcodec/imc.c
+++ b/libavcodec/imc.c
@@ -175,8 +175,10 @@ static av_cold int imc_decode_init(AVCodecContext *avctx)
IMCContext *q = avctx->priv_data;
double r1, r2;
- if ((avctx->codec_id == AV_CODEC_ID_IMC && avctx->channels != 1)
- || (avctx->codec_id == AV_CODEC_ID_IAC && avctx->channels > 2)) {
+ if (avctx->codec_id == AV_CODEC_ID_IMC)
+ avctx->channels = 1;
+
+ if (avctx->channels > 2) {
av_log_ask_for_sample(avctx, "Number of channels is not supported\n");
return AVERROR_PATCHWELCOME;
}