1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-02 11:21:42 +00:00

(find-alternate-file): Bind kill-buffer-query-functions locally, don't set it.

This commit is contained in:
Richard M. Stallman 2002-08-27 20:38:30 +00:00
parent 92c303103f
commit d97a9ff339
2 changed files with 9 additions and 3 deletions

View File

@ -1,3 +1,8 @@
2002-08-27 Richard M. Stallman <rms@gnu.org>
* files.el (find-alternate-file):
Bind kill-buffer-query-functions locally, don't set it.
2002-08-27 Andreas Schwab <schwab@suse.de>
* kmacro.el (kmacro-start-macro): Doc fix.

View File

@ -964,9 +964,10 @@ If the current buffer now contains an empty file that you just visited
(lock-buffer)
(rename-buffer oname)))
(unless (eq (current-buffer) obuf)
;; We already asked; don't ask again.
(setq kill-buffer-query-functions nil)
(kill-buffer obuf))))
(with-current-buffer obuf
;; We already asked; don't ask again.
(let ((kill-buffer-query-functions))
(kill-buffer obuf))))))
(defun create-file-buffer (filename)
"Create a suitably named buffer for visiting FILENAME, and return it.