Commit e07fcbdc authored by Stefan Monnier's avatar Stefan Monnier
Browse files

* lisp/files.el (find-alternate-file): Only ask one question.

Fixes: debbugs:12487
parent 1dc2755a
2012-10-29 Stefan Monnier <>
* files.el (find-alternate-file): Only ask one question (bug#12487).
2012-10-29 Chong Yidong <>
* vc/vc-hooks.el (vc-file-clearprops): Kill vc-parent-buffer.
......@@ -1537,12 +1537,9 @@ killed."
(unless (run-hook-with-args-until-failure 'kill-buffer-query-functions)
(error "Aborted"))
(when (and (buffer-modified-p) buffer-file-name)
(if (yes-or-no-p (format "Buffer %s is modified; save it first? "
(unless (yes-or-no-p "Kill and replace the buffer without saving it? ")
(error "Aborted"))))
(and (buffer-modified-p) buffer-file-name
(not (yes-or-no-p "Kill and replace the buffer without saving it? "))
(error "Aborted"))
(let ((obuf (current-buffer))
(ofile buffer-file-name)
(onum buffer-file-number)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment