[vlc-devel] [PATCH 11/18] aout: aout_DecNew: assert that arguments are valid

Thomas Guillem thomas at gllm.fr
Thu Mar 7 15:25:33 CET 2019


---
 src/audio_output/dec.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/audio_output/dec.c b/src/audio_output/dec.c
index e32dc19cee..d74d3b4a93 100644
--- a/src/audio_output/dec.c
+++ b/src/audio_output/dec.c
@@ -44,6 +44,8 @@ int aout_DecNew(audio_output_t *p_aout,
                 const audio_sample_format_t *p_format,
                 const audio_replay_gain_t *p_replay_gain)
 {
+    assert(p_aout);
+    assert(p_format);
     if( p_format->i_bitspersample > 0 )
     {
         /* Sanitize audio format, input need to have a valid physical channels
-- 
2.20.1



More information about the vlc-devel mailing list