[vlc-commits] demux: ts: really fix #14257

Francois Cartegnie git at videolan.org
Thu May 7 13:51:22 CEST 2015


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed May  6 18:56:50 2015 +0200| [9acc77358826a222405f75e1a75b80139ecd9d06] | committer: Francois Cartegnie

demux: ts: really fix #14257

We need to unselect missing PID on PMT update as some
providers add overlapping delay to the last packet of
prev pid.

reverts commit 50accb82e6e8b10a3f3493091dfcd832405ba234

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

 modules/demux/mpeg/ts.c |   18 ++----------------
 1 file changed, 2 insertions(+), 16 deletions(-)

diff --git a/modules/demux/mpeg/ts.c b/modules/demux/mpeg/ts.c
index 99fb4a6..7d8df00 100644
--- a/modules/demux/mpeg/ts.c
+++ b/modules/demux/mpeg/ts.c
@@ -5392,22 +5392,6 @@ static void PMTCallBack( void *data, dvbpsi_pmt_t *p_dvbpsipmt )
         } else dvbpsi_pmt_delete( p_dvbpsipmt );
     }
 
-    /* see es_out.c:2045 */
-    for( int i = 0; i < old_es_rm.i_size; i++ )
-    {
-        bool b_reset = false;
-        if( old_es_rm.p_elems[i]->u.p_pes->es.id )
-        {
-            es_out_Control( p_demux->out, ES_OUT_GET_ES_STATE,
-                            old_es_rm.p_elems[i]->u.p_pes->es.id, &b_reset );
-        }
-        if( b_reset )
-        {
-            es_out_Control( p_demux->out, ES_OUT_RESET_PCR );
-            break;
-        }
-    }
-
     /* Decref or clean now unused es */
     for( int i = 0; i < old_es_rm.i_size; i++ )
         PIDRelease( p_demux, old_es_rm.p_elems[i] );
@@ -5667,6 +5651,8 @@ static void ts_pes_Del( demux_t *p_demux, ts_pes_t *pes )
 {
     if( pes->es.id )
     {
+        /* Ensure we don't wait for overlap hacks #14257 */
+        es_out_Control( p_demux->out, ES_OUT_SET_ES_STATE, pes->es.id, false );
         es_out_Del( p_demux->out, pes->es.id );
         p_demux->p_sys->i_pmt_es--;
     }



More information about the vlc-commits mailing list