[PATCH 1/6] Fix few typos and compilation



There were a few field names used wrong, and also a mismatch between ItemsMap
and PropertiesMap.
---
 src/mp4_tag.cc | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/mp4_tag.cc b/src/mp4_tag.cc
index 2bd871b..a52c2fa 100644
--- a/src/mp4_tag.cc
+++ b/src/mp4_tag.cc
@@ -89,12 +89,12 @@ gboolean Mp4tag_Read_File_Tag (gchar *filename, File_Tag *FileTag)
     /**********
      * Artist *
      **********/
-    FileTag->artist = g_strdup (tag->title ().toCString (true));
+    FileTag->artist = g_strdup (tag->artist ().toCString (true));
 
     /*********
      * Album *
      *********/
-    FileTag->album = g_strdup (tag->title ().toCString (true));
+    FileTag->album = g_strdup (tag->album ().toCString (true));
 
     const TagLib::MP4::ItemListMap extra_tag = tag->itemListMap ();
 
@@ -186,7 +186,7 @@ gboolean Mp4tag_Write_File_Tag (ET_File *ETFile)
     File_Tag *FileTag;
     gchar    *filename;
     gchar    *filename_utf8;
-    TagLib::Tag *tag;
+    TagLib::MP4::Tag *tag;
     gboolean success;
 
     g_return_val_if_fail (ETFile != NULL && ETFile->FileTag != NULL, FALSE);
@@ -214,6 +214,8 @@ gboolean Mp4tag_Write_File_Tag (ET_File *ETFile)
         return FALSE;
     }
 
+    TagLib::MP4::ItemListMap &extra_tag = tag->itemListMap ();
+
     /*********
      * Title *
      *********/
@@ -276,8 +278,6 @@ gboolean Mp4tag_Write_File_Tag (ET_File *ETFile)
         tag->setComment (string);
     }
 
-    TagLib::MP4::ItemListMap extra_tag;
-
     /**********************
      * Composer or Writer *
      **********************/
@@ -308,7 +308,7 @@ gboolean Mp4tag_Write_File_Tag (ET_File *ETFile)
      ***********/
 
     /* FIXME: Add support to TagLib. */
-    tag->setProperties (extra_tag);
+    // tag->setProperties (extra_tag);
     success = mp4file.save () ? TRUE : FALSE;
 
     return success;
-- 
1.8.3.2



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