1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-08-15 14:13:16 +02:00

dca: Account for lfe when checking for the channel count

Bug-Id: 1037
CC: libav-stable@libav.org
This commit is contained in:
Luca Barbato
2017-04-17 12:53:14 +00:00
committed by Sean McGovern
parent 37f573543c
commit 5352802da8

View File

@@ -1300,7 +1300,7 @@ static int set_channel_layout(AVCodecContext *avctx, int channels)
s->channel_order_tab = ff_dca_channel_reorder_nolfe[s->amode];
}
if (channels < ff_dca_channels[s->amode])
if (channels < ff_dca_channels[s->amode] + !!s->lfe)
return AVERROR_INVALIDDATA;
if (channels > !!s->lfe &&