Fix exiting Emacs after saving a tutorial

* 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)
This commit is contained in:
Eli Zaretskii 2023-04-22 13:35:36 +03:00
parent 44145bf07e
commit dec2ac0c65

View 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)