[vlc-commits] adaptive: always call get_empty

Francois Cartegnie git at videolan.org
Mon Jul 31 18:26:01 CEST 2017


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Jul 19 18:42:58 2017 +0200| [b9b7a5a1adda9edc17f1a949d89991d8b9b2b1b6] | committer: Francois Cartegnie

adaptive: always call get_empty

As it should no longer freeze with audio

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

 modules/demux/adaptive/plumbing/FakeESOut.cpp | 18 +++---------------
 1 file changed, 3 insertions(+), 15 deletions(-)

diff --git a/modules/demux/adaptive/plumbing/FakeESOut.cpp b/modules/demux/adaptive/plumbing/FakeESOut.cpp
index acc00c0520..13348de38b 100644
--- a/modules/demux/adaptive/plumbing/FakeESOut.cpp
+++ b/modules/demux/adaptive/plumbing/FakeESOut.cpp
@@ -250,21 +250,9 @@ bool FakeESOut::hasSelectedEs() const
 
 bool FakeESOut::decodersDrained()
 {
-    bool b_drained = true;
-    std::list<FakeESOutID *>::const_iterator it;
-    vlc_mutex_lock(&lock);
-    for( it=fakeesidlist.begin(); it!=fakeesidlist.end(); ++it )
-    {
-        FakeESOutID *esID = *it;
-        if( esID->realESID() && esID->getFmt()->i_cat != AUDIO_ES ) /* Broken GET_EMPTY */
-        {
-            bool b_empty;
-            es_out_Control( real_es_out, ES_OUT_GET_EMPTY, &b_empty );
-            b_drained &= b_empty;
-        }
-    }
-    vlc_mutex_unlock(&lock);
-    return b_drained;
+    bool b_empty = true;
+    es_out_Control( real_es_out, ES_OUT_GET_EMPTY, &b_empty );
+    return b_empty;
 }
 
 bool FakeESOut::restarting() const



More information about the vlc-commits mailing list