jpegparse: return offset+length from _get_image_length().
authorStefan Kost <ensonic@users.sf.net>
Wed, 17 Feb 2010 10:34:38 +0000 (12:34 +0200)
committerStefan Kost <ensonic@users.sf.net>
Wed, 17 Feb 2010 11:12:00 +0000 (13:12 +0200)
_find_end_marker() find the position of the marker. EOI has a fixed length of 2
bytes that where missing. Fixes #608998

gst/jpegformat/gstjpegparse.c

index 64818cd..18aafd8 100644 (file)
@@ -425,8 +425,8 @@ gst_jpeg_parse_get_image_length (GstJpegParse * parse)
       offset = gst_jpeg_parse_find_end_marker (parse, data, size);
     }
   }
-
-  return offset;
+  /* position of EOI + the length of the marker */
+  return offset + 2;
 }
 
 static gboolean