Commit 9ff2971a authored by Rémi Duraffort's avatar Rémi Duraffort Committed by Jean-Baptiste Kempf

zip: fix memory leak (cid #1062581)

(cherry picked from commit ed69a40c887aa7550a6e8f1505c9b6388a7d2e5e)
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent d95795ab
......@@ -598,7 +598,12 @@ static int WriteXSPF( char **pp_buffer, vlc_array_t *p_filenames,
char *psz_path = strdup( psz_pathtozip );
char *psz_escapedName;
escapeToXml( &psz_escapedName, psz_name );
if( astrcatf( &psz_path, "%s", psz_escapedName ) < 0 ) return -1;
if( astrcatf( &psz_path, "%s", psz_escapedName ) < 0 )
{
free( psz_escapedName );
return -1;
}
free( psz_escapedName );
/* Track information */
if( astrcatf( pp_buffer,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment