[vlc-devel] [PATCH] faad decoder: fix decoding with some samples

Rafaël Carré funman at videolan.org
Tue Jun 4 14:45:35 CEST 2013


---
 modules/codec/faad.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/modules/codec/faad.c b/modules/codec/faad.c
index 664ce0e..6aba913 100644
--- a/modules/codec/faad.c
+++ b/modules/codec/faad.c
@@ -325,10 +325,11 @@ static block_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
         {
             msg_Warn( p_dec, "%s", faacDecGetErrorMessage( frame.error ) );
 
-            if( frame.error == 21 )
+            if( frame.error == 21 || frame.error == 12 )
             {
                 /*
-                 * Once an "Unexpected channel configuration change" error
+                 * Once an "Unexpected channel configuration change"
+                 * or a "Invalid number of channels" error
                  * occurs, it will occurs afterwards, and we got no sound.
                  * Reinitialization of the decoder is required.
                  */
-- 
1.8.1.2



More information about the vlc-devel mailing list