提交 8d77d12a 编写于 作者: J Justin Ruggles

dpcm: check to make sure channels is 1 or 2.

上级 4bad464e
......@@ -117,6 +117,11 @@ static av_cold int dpcm_decode_init(AVCodecContext *avctx)
int i;
short square;
if (avctx->channels < 1 || avctx->channels > 2) {
av_log(avctx, AV_LOG_INFO, "invalid number of channels\n");
return AVERROR(EINVAL);
}
s->channels = avctx->channels;
s->sample[0] = s->sample[1] = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册