vlc | branch: master | Ilkka Ollakka <il...@videolan.org> | Sat Oct 31 23:03:35 
2015 +0200| [707e35c83c21e13db15725c380e310d3ba1d6aaf] | committer: Ilkka 
Ollakka

stream_output: don't skip fifocount check on MuxGetStream

Even if we can add stream in any time, we should just continue
to next track if there isn't enough blocks in this track. Otherwise we
could try to query empty fifo.

ref #15747

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

 src/stream_output/stream_output.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/stream_output/stream_output.c 
b/src/stream_output/stream_output.c
index 539d2aa..3d87b9b 100644
--- a/src/stream_output/stream_output.c
+++ b/src/stream_output/stream_output.c
@@ -557,9 +557,10 @@ int sout_MuxGetStream( sout_mux_t *p_mux, unsigned 
i_blocks, mtime_t *pi_dts )
         sout_input_t *p_input = p_mux->pp_inputs[i];
         block_t *p_data;
 
-        if( (!p_mux->b_add_stream_any_time) && block_FifoCount( 
p_input->p_fifo ) < i_blocks )
+        if( block_FifoCount( p_input->p_fifo ) < i_blocks )
         {
-            if( p_input->p_fmt->i_cat != SPU_ES )
+            if( (!p_mux->b_add_stream_any_time) &&
+                (p_input->p_fmt->i_cat != SPU_ES ) )
             {
                 return -1;
             }

_______________________________________________
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to