libopusdec: default to stereo for invalid number of channels
authorAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Mon, 14 Nov 2016 20:41:45 +0000 (21:41 +0100)
committerAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Fri, 25 Nov 2016 21:22:11 +0000 (22:22 +0100)
commita6a2d9d1e546ecb7a697cfbc9f392f577e4d868c
treecf66277452f5dc040ad1337d2a815fd2ad7f7bfe
parent6ad27731428c93bcb3d7df91427b66a253206042
libopusdec: default to stereo for invalid number of channels

This fixes an out-of-bounds read if avc->channels is 0.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
(cherry picked from commit 8c8f543b81aa2b50bb6a6cfd370a0061281492a3)
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
libavcodec/libopusdec.c