[vlc-commits] es_out: ask for decoder drain on es_out_Del

Francois Cartegnie git at videolan.org
Mon Jul 31 18:25:53 CEST 2017


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Fri Jul 28 15:04:48 2017 +0200| [74c723fb3ccf3b73a33648f702e2c29ef13cf4e4] | committer: Francois Cartegnie

es_out: ask for decoder drain on es_out_Del

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.

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

 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 6a2e1cd83e..1e191d83a1 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 ) &&



More information about the vlc-commits mailing list