>From 95b63baf1bf411422c61b76470abb1aa681f2db2 Mon Sep 17 00:00:00 2001 From: Benjamin Riefenstahl Date: Tue, 17 Jan 2023 20:08:15 +0200 Subject: [PATCH 1/2] Fix decoding HTML files from archives * lisp/international/mule.el (sgml-xml-auto-coding-function): Avoid signaling an error from coding-system-equal when the XML encoding tag specifies an encoding whose type is 'charset'. (Bug#61005) This is the same fix as in #df7ed10e for sgml-xml-auto-coding-function. --- lisp/international/mule.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/international/mule.el b/lisp/international/mule.el index 4f6addea387..9480213be9a 100644 --- a/lisp/international/mule.el +++ b/lisp/international/mule.el @@ -2539,6 +2539,10 @@ sgml-html-meta-auto-coding-function (bfcs-type (coding-system-type buffer-file-coding-system))) (if (and enable-multibyte-characters + ;; 'charset' will signal an error in + ;; coding-system-equal, since it isn't a + ;; coding-system. So test that up front. + (not (equal sym-type 'charset)) (coding-system-equal 'utf-8 sym-type) (coding-system-equal 'utf-8 bfcs-type)) buffer-file-coding-system -- 2.30.2