[vlc-commits] demux: mp4: fix read overflow

Francois Cartegnie git at videolan.org
Mon Oct 31 21:38:56 CET 2016


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon Oct 31 21:37:22 2016 +0100| [311064b34c308c3039f04f2ab8ae2eeaf2278a98] | committer: Francois Cartegnie

demux: mp4: fix read overflow

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

 modules/demux/mp4/mp4.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/demux/mp4/mp4.c b/modules/demux/mp4/mp4.c
index b43c114..986d626 100644
--- a/modules/demux/mp4/mp4.c
+++ b/modules/demux/mp4/mp4.c
@@ -1206,7 +1206,7 @@ static int Demux( demux_t *p_demux )
         for( i_track = 0; i_track < p_sys->i_tracks; i_track++ )
         {
             mp4_track_t *tk = &p_sys->track[i_track];
-            if( !tk->b_ok || tk->b_chapters_source )
+            if( !tk->b_ok || tk->b_chapters_source || tk->i_sample_count == 0 )
                 continue;
             /* Test for EOF on each track (samples count, edit list) */
             b_eof &= ( i_nztime > MP4_TrackGetDTS( p_demux, tk ) );



More information about the vlc-commits mailing list