Commit f09ddd30 authored by Francois Cartegnie's avatar Francois Cartegnie

codec: opus: fix oob read (cid #1062575)

Opus supports up to 255 channels
parent 2f13bac4
......@@ -297,7 +297,7 @@ static int ProcessInitialHeader( decoder_t *p_dec, ogg_packet *p_oggpacket )
p_dec->fmt_out.audio.i_channels = p_header->channels;
p_dec->fmt_out.audio.i_rate = 48000;
if( p_header->channels>2 )
if( p_header->channels>2 && p_header->channels<9 )
{
static const uint32_t *pi_ch[6] = { pi_3channels_in, pi_4channels_in,
pi_5channels_in, pi_6channels_in,
......
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