[vlc-commits] demux: mp4: fix heap buffer ofw with zero chunk (fix #12356)
Francois Cartegnie
git at videolan.org
Thu Oct 9 13:41:34 CEST 2014
vlc/vlc-2.2 | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Oct 8 17:06:28 2014 +0200| [fc45e6cbdf909c372e708cca3e40911c3a5846fe] | committer: Jean-Baptiste Kempf
demux: mp4: fix heap buffer ofw with zero chunk (fix #12356)
(cherry picked from commit 929970aecfc91725ba243953ccb5197fa797c0a8)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.2.git/?a=commit;h=fc45e6cbdf909c372e708cca3e40911c3a5846fe
---
modules/demux/mp4/mp4.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules/demux/mp4/mp4.c b/modules/demux/mp4/mp4.c
index dad0ad0..27b3ed0 100644
--- a/modules/demux/mp4/mp4.c
+++ b/modules/demux/mp4/mp4.c
@@ -2118,7 +2118,7 @@ static void TrackGetESSampleRate( demux_t *p_demux,
return;
}
- if( p_track->i_chunk_count <= 0 )
+ if( p_track->i_chunk_count == 0 )
return;
/* */
@@ -2158,7 +2158,7 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track,
demux_sys_t *p_sys = p_demux->p_sys;
unsigned int i_sample_description_index;
- if( p_sys->b_fragmented )
+ if( p_sys->b_fragmented || p_track->i_chunk_count == 0 )
i_sample_description_index = 1; /* XXX */
else
i_sample_description_index =
More information about the vlc-commits
mailing list