[vlc-commits] sout: add an assertion

Rémi Denis-Courmont git at videolan.org
Thu May 7 19:06:50 CEST 2015


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu May  7 20:05:54 2015 +0300| [053ab8650c37456224562efc630b70b8652948f2] | committer: Rémi Denis-Courmont

sout: add an assertion

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=053ab8650c37456224562efc630b70b8652948f2
---

 src/stream_output/stream_output.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/stream_output/stream_output.c b/src/stream_output/stream_output.c
index bfdda15..b03bb84 100644
--- a/src/stream_output/stream_output.c
+++ b/src/stream_output/stream_output.c
@@ -548,6 +548,8 @@ int sout_MuxGetStream( sout_mux_t *p_mux, unsigned i_blocks, mtime_t *pi_dts )
     mtime_t i_dts = 0;
     int     i_stream = -1;
 
+    assert( i_blocks > 0 );
+
     for( int i = 0; i < p_mux->i_nb_inputs; i++ )
     {
         sout_input_t *p_input = p_mux->pp_inputs[i];



More information about the vlc-commits mailing list