From f8254aad149b770781b3b0daaae7f49d1b1b8742 Mon Sep 17 00:00:00 2001 From: Juri Linkov Date: Sun, 15 Mar 2020 01:58:58 +0200 Subject: [PATCH] * lisp/image/image-converter.el: Support more ImageMagick versions (bug#39994) * lisp/image/image-converter.el (image-converter--probe): Match a possible additional second column in some ImageMagick versions of "convert -list format". --- lisp/image/image-converter.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/image/image-converter.el b/lisp/image/image-converter.el index 0488a13d41a..ae3d9598920 100644 --- a/lisp/image/image-converter.el +++ b/lisp/image/image-converter.el @@ -149,8 +149,9 @@ data is returned as a string." (when (re-search-forward "^-" nil t) (forward-line 1) ;; Lines look like - ;; " WPG* r-- Word Perfect Graphics". - (while (re-search-forward "^ *\\([A-Z0-9]+\\)\\*? +r" nil t) + ;; " WPG* r-- Word Perfect Graphics" or + ;; " WPG* WPG r-- Word Perfect Graphics". + (while (re-search-forward "^ *\\([A-Z0-9]+\\)\\*?\\(?: +[A-Z0-9]+\\)? +r" nil t) (push (downcase (match-string 1)) formats))) (nreverse formats)))) -- 2.39.2