[vlc-commits] Fix use-after-free (cid #1047498 and #1047499)

Rémi Duraffort git at videolan.org
Sat Jul 13 15:31:25 CEST 2013


vlc/vlc-2.1 | branch: master | Rémi Duraffort <ivoire at videolan.org> | Sat Jul 13 08:37:54 2013 +0200| [9e8ac7f7bed6f248fb9a46e5b8d4d2086ee9b789] | committer: Jean-Baptiste Kempf

Fix use-after-free (cid #1047498 and #1047499)

(cherry picked from commit dea05a9dc548c7fd8af9150c28c3d3011449ebfb)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

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

 modules/demux/playlist/m3u.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/demux/playlist/m3u.c b/modules/demux/playlist/m3u.c
index b995895..599105e 100644
--- a/modules/demux/playlist/m3u.c
+++ b/modules/demux/playlist/m3u.c
@@ -203,8 +203,8 @@ static int Demux( demux_t *p_demux )
             {
                 /* Extended info */
                 psz_parse += sizeof("EXTINF:") - 1;
-                free(psz_name);
-                free(psz_artist);
+                FREENULL( psz_name );
+                FREENULL( psz_artist );
                 parseEXTINF( psz_parse, &psz_artist, &psz_name, &i_parsed_duration );
                 if( i_parsed_duration >= 0 )
                     i_duration = i_parsed_duration * INT64_C(1000000);



More information about the vlc-commits mailing list