[vlc-commits] ts: use vlc_alloc helper

Thomas Guillem git at videolan.org
Sat Nov 11 19:00:11 CET 2017


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Sat Nov 11 18:45:32 2017 +0100| [f4f36d94f9eb3ae5d1be5d0f554d9c0766a26b19] | committer: Thomas Guillem

ts: use vlc_alloc helper

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

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

diff --git a/modules/demux/mpeg/ts.c b/modules/demux/mpeg/ts.c
index e8f7d3d266..0fa65d7263 100644
--- a/modules/demux/mpeg/ts.c
+++ b/modules/demux/mpeg/ts.c
@@ -1139,7 +1139,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
         if( *pi_int <= 0 )
             return VLC_EGENERIC;
 
-        *ppp_attach = malloc( sizeof(input_attachment_t*) * *pi_int );
+        *ppp_attach = vlc_alloc( *pi_int, sizeof(input_attachment_t*) );
         if( !*ppp_attach )
             return VLC_EGENERIC;
 



More information about the vlc-commits mailing list