[vlc-commits] mux: libmp4: check alloc
Francois Cartegnie
git at videolan.org
Wed Oct 23 13:20:54 CEST 2019
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon Oct 21 11:57:38 2019 +0200| [892a13d9bfff10dda8b6935ef07092858131463e] | committer: Francois Cartegnie
mux: libmp4: check alloc
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=892a13d9bfff10dda8b6935ef07092858131463e
---
modules/mux/mp4/libmp4mux.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/modules/mux/mp4/libmp4mux.c b/modules/mux/mp4/libmp4mux.c
index 7b6a37f22e..1e26c5cab7 100644
--- a/modules/mux/mp4/libmp4mux.c
+++ b/modules/mux/mp4/libmp4mux.c
@@ -140,7 +140,7 @@ mp4mux_trackinfo_t * mp4mux_track_Add(mp4mux_handle_t *h, unsigned id,
const es_format_t *fmt, uint32_t timescale)
{
mp4mux_trackinfo_t *t = malloc(sizeof(*t));
- if(!mp4mux_trackinfo_Init(t, 0, 0))
+ if(!t || !mp4mux_trackinfo_Init(t, 0, 0))
{
free(t);
return NULL;
More information about the vlc-commits
mailing list