After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 411861 - Jpegtran/libjpeg writes a JFIF marker, which is incompatible with EXIF
Jpegtran/libjpeg writes a JFIF marker, which is incompatible with EXIF
Status: RESOLVED FIXED
Product: gthumb
Classification: Other
Component: general
2.9.x
Other All
: Normal normal
: ---
Assigned To: Paolo Bacchilega
Paolo Bacchilega
Depends on:
Blocks:
 
 
Reported: 2007-02-25 11:25 UTC by Jef Driesen
Modified: 2007-03-23 18:24 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Omit the JFIF marker if an EXIF marker is found (4.59 KB, patch)
2007-03-06 15:28 UTC, Jef Driesen
none Details | Review
Omit all markers for the EXIF thumbnail (4.96 KB, patch)
2007-03-23 15:19 UTC, Jef Driesen
none Details | Review

Description Jef Driesen 2007-02-25 11:25:38 UTC
Please describe the problem:
jpegtran/libjpeg creates jpeg files with a JFIF (APP0) marker, which is incompatible with Exif. The Exif standard requires that the EXIF (APP1) marker be first extra marker, but JFIF has the same requirement.

Steps to reproduce:


Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Jef Driesen 2007-02-25 11:58:48 UTC
More information on the issue can be found here:

http://sylvana.net/jpegcrop/exifpatch.html
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=106060

The JFIF marker can be omitted by setting "dstinfo.write_JFIF_header = FALSE;" for exif files.

I also found bug 334481 for f-spot, which is probably caused by this issue.
Comment 2 Jef Driesen 2007-03-06 15:28:20 UTC
Created attachment 84074 [details] [review]
Omit the JFIF marker if an EXIF marker is found
Comment 3 Michael Chudobiak 2007-03-06 16:51:47 UTC
Patch committed to trunk and metadata-ideas (where the JFIF tags are shown in the metadata view).

Thanks!

- Mike
Comment 4 Jef Driesen 2007-03-23 15:10:22 UTC
I noticed an similar problems for the exif thumbnails. According to the EXIF specs, the thumbnail should not contain any APPn or COM markers. But jpegtran does write a JFIF marker by default.
Comment 5 Jef Driesen 2007-03-23 15:19:32 UTC
Created attachment 85178 [details] [review]
Omit all markers for the EXIF thumbnail

This patch suppresses all APPn and COM markers for the EXIF thumbnail.

I also moved the jpegtran_internal "path" parameter to the mcu callback "userdata" parameter, because I believe that is where it belongs. (I can provide a patch without this change if required.)
Comment 6 Michael Chudobiak 2007-03-23 18:24:34 UTC
Patch applied; thanks!

- Mike