? gst/id3demux/TODO
? gst/id3demux/id3v2.3.0.txt
Index: gst/id3demux/id3v2frames.c
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/gst/id3demux/id3v2frames.c,v
retrieving revision 1.22
diff -u -p -u -r1.22 id3v2frames.c
--- gst/id3demux/id3v2frames.c	22 Jun 2006 12:17:13 -0000	1.22
+++ gst/id3demux/id3v2frames.c	18 Aug 2006 13:57:21 -0000
@@ -255,12 +255,12 @@ parse_text_identification_frame (ID3Tags
       work->parse_size - 1, &fields);
   if (fields) {
     if (fields->len > 0) {
-      GST_LOG ("Read %d fields from Text ID frame of size %d. First is '%s'",
-          fields->len, work->parse_size - 1,
+      GST_LOG ("Read %d fields from Text ID frame of size %d with encoding %d"
+          ". First is '%s'", fields->len, work->parse_size - 1, encoding,
           g_array_index (fields, gchar *, 0));
     } else {
-      GST_LOG ("Read %d fields from Text ID frame of size %d", fields->len,
-          work->parse_size - 1);
+      GST_LOG ("Read 0 fields from Text ID frame of size %d with encoding %d",
+          work->parse_size - 1, encoding);
     }
   }
 
@@ -893,8 +893,11 @@ parse_insert_string_field (guint8 encodi
 
       break;
     case ID3V2_ENCODING_ISO8859:
-      field = g_convert (data, data_size, "UTF-8", "ISO-8859-1",
-          NULL, NULL, NULL);
+      if (g_utf8_validate (data, data_size, NULL))
+        field = g_strndup (data, data_size);
+      else
+        field = g_convert (data, data_size, "UTF-8", "ISO-8859-1",
+            NULL, NULL, NULL);
       break;
     default:
       field = g_strndup (data, data_size);
