25 lines
784 B
Diff
25 lines
784 B
Diff
Fix segmentation fault in playlist wrt http://bugs.gentoo.org/390783 by Rafał Mużyło
|
||
|
||
--- src/playlist.c
|
||
+++ src/playlist.c
|
||
@@ -427,7 +427,7 @@ static int playlist_load (const char *fn
|
||
if (errno != ENOENT && (defaultfile || errno != ENOTDIR))
|
||
display_error (FROM_GXINE, _("Loading of playlist file failed."),
|
||
_("Failed to open file ‘%s’\n%s"), fname, strerror (errno));
|
||
- goto ret0;
|
||
+ goto ret1;
|
||
}
|
||
|
||
xml_parser_init_R (xml_parser_t *xml, plfile, st.st_size, XML_PARSER_CASE_INSENSITIVE);
|
||
@@ -524,9 +524,10 @@ static int playlist_load (const char *fn
|
||
return 1;
|
||
|
||
ret0:
|
||
- free (plfile);
|
||
xml_parser_free_tree (root);
|
||
xml_parser_finalize_R (xml);
|
||
+ free (plfile);
|
||
+ ret1:
|
||
if (defaultfile)
|
||
free ((char *)fname);
|
||
return ret;
|