emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

emacs-29 17d803d0a75: Fix detection of WebP images by their signature


From: Eli Zaretskii
Subject: emacs-29 17d803d0a75: Fix detection of WebP images by their signature
Date: Wed, 12 Apr 2023 13:04:21 -0400 (EDT)

branch: emacs-29
commit 17d803d0a7545db360c917e576aa77cea10a9b29
Author: Visuwesh <visuweshm@gmail.com>
Commit: Eli Zaretskii <eliz@gnu.org>

    Fix detection of WebP images by their signature
    
    * lisp/image.el (image-type-header-regexps): The 4 characters
    between "RIFF" and "WEBP" in WebP images can also be newlines.
    (Bug#62790)
---
 lisp/image.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/image.el b/lisp/image.el
index 6a8293fedf3..104fea407ff 100644
--- a/lisp/image.el
+++ b/lisp/image.el
@@ -51,7 +51,7 @@ static \\(unsigned \\)?char \\1_bits" . xbm)
     ("\\`\\(?:MM\0\\*\\|II\\*\0\\)" . tiff)
     ("\\`[\t\n\r ]*%!PS" . postscript)
     ("\\`\xff\xd8" . jpeg)    ; used to be (image-jpeg-p . jpeg)
-    ("\\`RIFF....WEBPVP8" . webp)
+    ("\\`RIFF[^z-a][^z-a][^z-a][^z-a]WEBPVP8" . webp)
     (,(let* ((incomment-re "\\(?:[^-]\\|-[^-]\\)")
             (comment-re (concat "\\(?:!--" incomment-re "*-->[ \t\r\n]*<\\)")))
        (concat "\\(?:<\\?xml[ \t\r\n]+[^>]*>\\)?[ \t\r\n]*<"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]