branch: externals/transient
commit e3644faf15644630e1e234d23c5be3b9f90a8b8e
Author: Jonas Bernoulli <jo...@bernoul.li>
Commit: Jonas Bernoulli <jo...@bernoul.li>

    transient-maybe-save-history: Demote error
    
    Since this function is added to `kill-emacs-hook', an error here makes
    it impossible to close Emacs.  In normal use errors are very unlikely,
    but due to a backward incompatible change in `generate-new-buffer' it
    does happen when I quickly use an older Emacs without recompiling this
    library.
---
 lisp/transient.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lisp/transient.el b/lisp/transient.el
index c3941b5ed8..c45b869962 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -747,7 +747,8 @@ should not change it manually.")
   "Save the value of `transient-history'.
 If `transient-save-history' is nil, then do nothing."
   (when transient-save-history
-    (transient-save-history)))
+    (with-demoted-errors "Error saving transient history: %S"
+      (transient-save-history))))
 
 (unless noninteractive
   (add-hook 'kill-emacs-hook #'transient-maybe-save-history))

Reply via email to