[vlc-commits] vout: ios: fix leak

Thomas Guillem git at videolan.org
Fri Sep 8 14:25:31 CEST 2017


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Fri Sep  8 14:23:23 2017 +0200| [92c3236ab91325f54bde0d52e2328fbf2138cd2b] | committer: Thomas Guillem

vout: ios: fix leak

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

 modules/video_output/ios.m | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/modules/video_output/ios.m b/modules/video_output/ios.m
index beeb56f689..3331249e55 100644
--- a/modules/video_output/ios.m
+++ b/modules/video_output/ios.m
@@ -180,7 +180,8 @@ static int Open(vlc_object_t *this)
         if (!sys->gl)
             goto bailout;
 
-        struct gl_sys *glsys = sys->gl->sys = malloc(sizeof(struct gl_sys));
+        struct gl_sys *glsys = sys->gl->sys =
+            vlc_malloc(sys->gl, sizeof(struct gl_sys));
         if (unlikely(!sys->gl->sys))
             goto bailout;
         glsys->locked_ctx = NULL;



More information about the vlc-commits mailing list