[vlc-commits] mkv: removed EbmlParser::UnGet

Filip Roséen git at videolan.org
Mon May 9 15:09:31 CEST 2016


vlc | branch: master | Filip Roséen <filip at videolabs.io> | Mon May  9 14:53:20 2016 +0200| [c2c9a34121439d4eb4af20571e1ab7e764cfe4be] | committer: Jean-Baptiste Kempf

mkv: removed EbmlParser::UnGet

This function is never called, and it will probably never be in the
future.

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

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

 modules/demux/mkv/Ebml_parser.cpp |   38 -------------------------------------
 modules/demux/mkv/Ebml_parser.hpp |    1 -
 2 files changed, 39 deletions(-)

diff --git a/modules/demux/mkv/Ebml_parser.cpp b/modules/demux/mkv/Ebml_parser.cpp
index d0abab7..822c1c7 100644
--- a/modules/demux/mkv/Ebml_parser.cpp
+++ b/modules/demux/mkv/Ebml_parser.cpp
@@ -77,44 +77,6 @@ void EbmlParser::reconstruct( EbmlStream* es, EbmlElement* el_start, demux_t* p_
     );
 }
 
-EbmlElement* EbmlParser::UnGet( uint64 i_block_pos, uint64 i_cluster_pos )
-{
-    if ( mi_user_level > mi_level )
-    {
-        while ( mi_user_level != mi_level )
-        {
-            delete m_el[mi_user_level];
-            m_el[mi_user_level] = NULL;
-            mi_user_level--;
-        }
-    }
-
-    /* Avoid data skip in BlockGet */
-    delete m_el[mi_level];
-    m_el[mi_level] = NULL;
-
-    m_got = NULL;
-    mb_keep = false;
-    if ( m_el[1] && m_el[1]->GetElementPosition() == i_cluster_pos )
-    {
-        m_es->I_O().setFilePointer( i_block_pos, seek_beginning );
-        return m_el[1];
-    }
-    else
-    {
-        // seek to the previous Cluster
-        m_es->I_O().setFilePointer( i_cluster_pos, seek_beginning );
-        while(mi_level > 1)
-        {
-            mi_level--;
-            mi_user_level--;
-            delete m_el[mi_level];
-            m_el[mi_level] = NULL;
-        }
-        return NULL;
-    }
-}
-
 void EbmlParser::Up( void )
 {
     if( mi_user_level == mi_level && m_el[mi_level] )
diff --git a/modules/demux/mkv/Ebml_parser.hpp b/modules/demux/mkv/Ebml_parser.hpp
index 596e7ec..320b1f5 100644
--- a/modules/demux/mkv/Ebml_parser.hpp
+++ b/modules/demux/mkv/Ebml_parser.hpp
@@ -46,7 +46,6 @@ class EbmlParser
     EbmlElement *Get( int n_call = 0 );
     void        Keep( void );
     void        Unkeep( void );
-    EbmlElement *UnGet( uint64 i_block_pos, uint64 i_cluster_pos );
 
     int  GetLevel( void ) const;
 



More information about the vlc-commits mailing list