projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19f37af
)
Make html-mode--html-yank-handler more resilient
author
Lars Ingebrigtsen
<larsi@gnus.org>
Mon, 8 Nov 2021 05:04:11 +0000
(06:04 +0100)
committer
Lars Ingebrigtsen
<larsi@gnus.org>
Mon, 8 Nov 2021 05:04:11 +0000
(06:04 +0100)
* lisp/textmodes/sgml-mode.el (html-mode--html-yank-handler): The
HTML may not be valid, so suppress errors.
lisp/textmodes/sgml-mode.el
patch
|
blob
|
history
diff --git
a/lisp/textmodes/sgml-mode.el
b/lisp/textmodes/sgml-mode.el
index 3b0c5d8b65c03a0bcf9586893b413213bb9b99ff..dedc38821998b69e0121b00f06a1cf52a6128acc 100644
(file)
--- a/
lisp/textmodes/sgml-mode.el
+++ b/
lisp/textmodes/sgml-mode.el
@@
-2435,7
+2435,8
@@
To work around that, do:
(defun html-mode--html-yank-handler (_type html)
(save-restriction
(insert html)
- (sgml-pretty-print (point-min) (point-max))))
+ (ignore-errors
+ (sgml-pretty-print (point-min) (point-max)))))
(defun html-mode--image-yank-handler (type image)
(let ((file (read-file-name (format "Save %s image to: " type))))