[vlc-devel] [PATCH 1/2] es_out: ask for decoder drain on es_out_Del

Francois Cartegnie fcvlcdev at free.fr
Fri Jul 28 17:06:13 CEST 2017


because when the es deletion is triggered by
demuxer and not on EOF, it enters a dead loop
waiting for input_DecoderIsEmpty (p_owner->drained).
non set p_owner->draining can't trigger p_owner->drained.
---
 src/input/es_out.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/input/es_out.c b/src/input/es_out.c
index 6a2e1cd..1e191d8 100644
--- a/src/input/es_out.c
+++ b/src/input/es_out.c
@@ -2114,6 +2114,7 @@ static void EsOutDel( es_out_t *out, es_out_id_t *es )
     {   /* FIXME: This might hold the ES output caller (i.e. the demux), and
          * the corresponding thread (typically the input thread), for a little
          * bit too long if the ES is deleted in the middle of a stream. */
+        input_DecoderDrain( es->p_dec );
         while( !input_Stopped(p_sys->p_input) && !p_sys->b_buffering )
         {
             if( input_DecoderIsEmpty( es->p_dec ) &&
-- 
2.9.4



More information about the vlc-devel mailing list