[vlc-commits] mp4 demux: fix memory leak when demuxing (e)ac-3
Rafaël Carré
git at videolan.org
Wed Sep 3 13:15:57 CEST 2014
vlc | branch: master | Rafaël Carré <funman at videolan.org> | Wed Sep 3 13:02:19 2014 +0200| [64dbbc38df35d3ff5ff6efdbec3913c23d429903] | committer: Rafaël Carré
mp4 demux: fix memory leak when demuxing (e)ac-3
the default handler would read them as soun atom but fail to free them
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=64dbbc38df35d3ff5ff6efdbec3913c23d429903
---
modules/demux/mp4/libmp4.c | 2 ++
modules/demux/mp4/libmp4.h | 2 ++
2 files changed, 4 insertions(+)
diff --git a/modules/demux/mp4/libmp4.c b/modules/demux/mp4/libmp4.c
index f51416e..66f5db2 100644
--- a/modules/demux/mp4/libmp4.c
+++ b/modules/demux/mp4/libmp4.c
@@ -3394,6 +3394,8 @@ static const struct
/* for codecs */
{ ATOM_soun, MP4_ReadBox_sample_soun, MP4_FreeBox_sample_soun, ATOM_stsd },
+ { ATOM_ac3, MP4_ReadBox_sample_soun, MP4_FreeBox_sample_soun, ATOM_stsd },
+ { ATOM_eac3, MP4_ReadBox_sample_soun, MP4_FreeBox_sample_soun, ATOM_stsd },
{ ATOM_lpcm, MP4_ReadBox_sample_soun, MP4_FreeBox_sample_soun, ATOM_stsd },
{ ATOM_ms02, MP4_ReadBox_sample_soun, MP4_FreeBox_sample_soun, ATOM_stsd },
{ ATOM_ms11, MP4_ReadBox_sample_soun, MP4_FreeBox_sample_soun, ATOM_stsd },
diff --git a/modules/demux/mp4/libmp4.h b/modules/demux/mp4/libmp4.h
index d2a5424..b6c8fa4 100644
--- a/modules/demux/mp4/libmp4.h
+++ b/modules/demux/mp4/libmp4.h
@@ -134,6 +134,8 @@
#define ATOM_sawb VLC_FOURCC( 's', 'a', 'w', 'b' )
#define ATOM_OggS VLC_FOURCC( 'O', 'g', 'g', 'S' )
#define ATOM_alac VLC_FOURCC( 'a', 'l', 'a', 'c' )
+#define ATOM_ac3 VLC_FOURCC( 'a', 'c', '-', '3' )
+#define ATOM_eac3 VLC_FOURCC( 'e', 'c', '-', '3' )
#define ATOM_dac3 VLC_FOURCC( 'd', 'a', 'c', '3' )
#define ATOM_dec3 VLC_FOURCC( 'd', 'e', 'c', '3' )
#define ATOM_dvc1 VLC_FOURCC( 'd', 'v', 'c', '1' )
More information about the vlc-commits
mailing list