Commit 5982078e authored by Marton Balint's avatar Marton Balint

avcodec/utils: report insane channel count errors

More than 64 is not *that* insane, so let's report the error at least.
Signed-off-by: 's avatarMarton Balint <cus@passwd.hu>
parent 85bfcc46
......@@ -674,6 +674,7 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, const AVCodec *code
av_freep(&avctx->subtitle_header);
if (avctx->channels > FF_SANE_NB_CHANNELS) {
av_log(avctx, AV_LOG_ERROR, "Too many channels: %d\n", avctx->channels);
ret = AVERROR(EINVAL);
goto free_and_end;
}
......
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