[easytag] Fix memory leak in ogg_tag_read_file_tag()



commit ad49c309811981aed03d376a37ae43217dbdce25
Author: David King <amigadave amigadave com>
Date:   Wed Feb 26 20:43:35 2014 +0000

    Fix memory leak in ogg_tag_read_file_tag()

 src/ogg_tag.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/ogg_tag.c b/src/ogg_tag.c
index 53a6597..c7990c7 100644
--- a/src/ogg_tag.c
+++ b/src/ogg_tag.c
@@ -190,7 +190,7 @@ ogg_tag_read_file_tag (gchar *filename, File_Tag *FileTag, GError **error)
     gchar          *string = NULL;
     gchar          *string1 = NULL;
     gchar          *string2 = NULL;
-    gchar          *filename_utf8 = filename_to_display(filename);
+    gchar *filename_utf8;
     guint           field_num, i;
     Picture        *prev_pic = NULL;
 
@@ -207,6 +207,8 @@ ogg_tag_read_file_tag (gchar *filename, File_Tag *FileTag, GError **error)
         return FALSE;
     }
 
+    filename_utf8 = filename_to_display (filename);
+
     {
     // Skip the id3v2 tag
     guchar tmp_id3[4];


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]