vorbisdec: Check for empty tag strings. Fixes #588724
authorEdward Hervey <bilboed@bilboed.com>
Thu, 16 Jul 2009 07:32:46 +0000 (09:32 +0200)
committerEdward Hervey <bilboed@bilboed.com>
Thu, 16 Jul 2009 12:15:19 +0000 (14:15 +0200)
ext/vorbis/vorbisdec.c

index e440085..6cc2bac 100644 (file)
@@ -726,8 +726,9 @@ vorbis_handle_comment_packet (GstVorbisDec * vd, ogg_packet * packet)
     vd->taglist = gst_tag_list_new ();
   }
   if (encoder) {
-    gst_tag_list_add (vd->taglist, GST_TAG_MERGE_REPLACE,
-        GST_TAG_ENCODER, encoder, NULL);
+    if (encoder[0])
+      gst_tag_list_add (vd->taglist, GST_TAG_MERGE_REPLACE,
+          GST_TAG_ENCODER, encoder, NULL);
     g_free (encoder);
   }
   gst_tag_list_add (vd->taglist, GST_TAG_MERGE_REPLACE,