From: Stefan Kost Date: Mon, 11 Apr 2011 15:31:45 +0000 (+0300) Subject: jpegparse: subtract id-str size from the remaining read X-Git-Tag: 1.19.3~507^2~16050^2~352 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b84dd0a766ab4098e64ddc591c3c9031a313afe8;p=platform%2Fupstream%2Fgstreamer.git jpegparse: subtract id-str size from the remaining read Fixes a regression from the patches in bug #626618. --- diff --git a/gst/jpegformat/gstjpegparse.c b/gst/jpegformat/gstjpegparse.c index cb10ef88b9..65e249c5e7 100644 --- a/gst/jpegformat/gstjpegparse.c +++ b/gst/jpegformat/gstjpegparse.c @@ -623,6 +623,7 @@ gst_jpeg_parse_app1 (GstJpegParse * parse, GstByteReader * reader) /* skip id + NUL + padding */ if (!gst_byte_reader_skip (reader, 6)) return FALSE; + size -= 6; /* handle exif metadata */ if (!gst_byte_reader_get_data (reader, size, &data)) @@ -639,6 +640,7 @@ gst_jpeg_parse_app1 (GstJpegParse * parse, GstByteReader * reader) /* skip the id + NUL */ if (!gst_byte_reader_skip (reader, 29)) return FALSE; + size -= 29; /* handle xmp metadata */ if (!gst_byte_reader_get_data (reader, size, &data))