[vlc-commits] stream: fix memory leak on error

Rémi Denis-Courmont git at videolan.org
Sun Jul 26 14:38:50 CEST 2015


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Jul 26 13:42:56 2015 +0300| [f5375e68d6d2888cc8bd2fa8fc0ce1119a1439d7] | committer: Rémi Denis-Courmont

stream: fix memory leak on error

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

 src/input/stream_memory.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/src/input/stream_memory.c b/src/input/stream_memory.c
index 74d9b72..6140398 100644
--- a/src/input/stream_memory.c
+++ b/src/input/stream_memory.c
@@ -64,6 +64,7 @@ stream_t *stream_MemoryNew( vlc_object_t *p_this, uint8_t *p_buffer,
     if( !s->psz_path || !s->p_sys )
     {
         stream_CommonDelete( s );
+        free( p_sys );
         return NULL;
     }
     p_sys->i_pos = 0;



More information about the vlc-commits mailing list