GNU bug report logs -
#40127
27.0.90; image-mode fails on all images with short EXIF tags
Previous Next
Reported by: Juri Linkov <juri <at> linkov.net>
Date: Wed, 18 Mar 2020 23:59:02 UTC
Severity: normal
Tags: fixed
Found in version 27.0.90
Fixed in version 27.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
I realized that the 4th problem reported in bug#39994 is not related to
image-converter.el, so here is a separate bug report.
The problem is that currently image-mode fails to open all image files
where one of EXIF tags is shorter than 4 bytes. So none of the
images created by a device whose EXIF tag "Manufacturer" is "HTC"
can not be opened in Emacs 27.
Here's is the patch that at least allows opening any image
ignoring errors in EXIF parser implementation:
diff --git a/lisp/image-mode.el b/lisp/image-mode.el
index 22d7d91314..10900be33f 100644
--- a/lisp/image-mode.el
+++ b/lisp/image-mode.el
@@ -769,7 +769,7 @@ image-toggle-display-image
;; Get the rotation data from the file, if any.
(setq image-transform-rotation
(or (exif-orientation
- (ignore-error exif-error
+ (ignore-errors
(exif-parse-buffer)))
0.0))
This bug report was last modified 5 years and 121 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.