vlc | branch: master | Hugo Beauzée-Luyssen <[email protected]> | Mon Aug 12 
12:04:14 2019 +0200| [24f37e539c25359d2d963713bbafb861ed80bcf7] | committer: 
Hugo Beauzée-Luyssen

asf: Fix leak on duplicated stream ids

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

 modules/demux/asf/asf.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/modules/demux/asf/asf.c b/modules/demux/asf/asf.c
index d9f359fcd3..9bc4b3de70 100644
--- a/modules/demux/asf/asf.c
+++ b/modules/demux/asf/asf.c
@@ -873,6 +873,10 @@ static int DemuxInit( demux_t *p_demux )
                                i_stream );
         p_esp = NULL;
 
+        /* Ignore duplicated streams numbers */
+        if (p_sys->track[p_sp->i_stream_number])
+            continue;
+
         tk = p_sys->track[p_sp->i_stream_number] = malloc( sizeof( asf_track_t 
) );
         if (!tk)
             goto error;

_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to