gst_plugins_base/gst-libs/gst/riff/riff-read.c
branchRCL_3
changeset 30 7e817e7e631c
parent 29 567bb019e3e3
--- a/gst_plugins_base/gst-libs/gst/riff/riff-read.c	Tue Aug 31 15:30:33 2010 +0300
+++ b/gst_plugins_base/gst-libs/gst/riff/riff-read.c	Wed Sep 01 12:16:41 2010 +0100
@@ -161,10 +161,6 @@
   GST_DEBUG_OBJECT (element, "fourcc=%" GST_FOURCC_FORMAT ", size=%u",
       GST_FOURCC_ARGS (fourcc), size);
 
-  /* be paranoid: size may be nonsensical value here, such as (guint) -1 */
-  if (G_UNLIKELY (size > G_MAXINT))
-    goto bogus_size;
-
   if (bufsize < size + 8 + offset) {
     GST_DEBUG_OBJECT (element,
         "Needed chunk data (%d) is more than available (%d), shortcutting",
@@ -195,11 +191,6 @@
         offset, bufsize, 8);
     return FALSE;
   }
-bogus_size:
-  {
-    GST_ERROR_OBJECT (element, "Broken file: bogus chunk size %u", size);
-    return FALSE;
-  }
 }
 
 /**
@@ -655,10 +646,6 @@
     tsize = GST_READ_UINT32_LE (data + 4);
     size -= 8;
     data += 8;
-
-    GST_DEBUG ("tag %" GST_FOURCC_FORMAT ", size %u",
-        GST_FOURCC_ARGS (tag), tsize);
-
     if (tsize > size) {
       GST_WARNING_OBJECT (element,
           "Tagsize %d is larger than available data %d", tsize, size);
@@ -701,7 +688,7 @@
         type = GST_TAG_GENRE;
         break;
       case GST_RIFF_INFO_IKEY:
-        type = GST_TAG_KEYWORDS;
+        type = NULL; /*"Keywords"; */ ;
         break;
       case GST_RIFF_INFO_ILGT:
         type = NULL;            /*"Lightness"; */
@@ -760,12 +747,6 @@
       }
     }
 
-    if (tsize & 1) {
-      tsize++;
-      if (tsize > size)
-        tsize = size;
-    }
-
     data += tsize;
     size -= tsize;
   }