]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix exiting Emacs after saving a tutorial
authorEli Zaretskii <eliz@gnu.org>
Sat, 22 Apr 2023 10:35:36 +0000 (13:35 +0300)
committerEli Zaretskii <eliz@gnu.org>
Sat, 22 Apr 2023 10:35:36 +0000 (13:35 +0300)
* lisp/tutorial.el (tutorial--starting-point): Make it
permanent-local, so that saving the tutorial to some file doesn't
kill this buffer-local variable.  Otherwise, trying to exit Emacs
after saving the tutorial will signal an error, because
'tutorial--starting-point' is void.  (Bug#37326)

lisp/tutorial.el

index 0afe565c80b7e5b80a85ad63bd513fb38dae9958..eb494be8d4d0032829037bd0e2a3cacf1458a931 100644 (file)
@@ -650,6 +650,7 @@ with some explanatory links."
          (delete-region prop-start prop-end))))))
 
 (defvar tutorial--starting-point)
+(put 'tutorial--starting-point 'permanent-local t)
 (defun tutorial--save-on-kill ()
   "Query the user about saving the tutorial when killing Emacs."
   (when (buffer-live-p tutorial--buffer)