diff options
author | Martin Rudalics <rudalics@gmx.at> | 2019-10-17 19:35:29 +0200 |
---|---|---|
committer | Martin Rudalics <rudalics@gmx.at> | 2019-10-17 19:35:29 +0200 |
commit | 34923412b5a5888f0f50b3009a6225670be4c026 (patch) | |
tree | b8704d6700e11787f3037d3697a8b1c43cc6ee44 /lisp/window.el | |
parent | 9e44d3373b8ec545c7aa8659446e339c176377c2 (diff) | |
download | emacs-34923412b5a5888f0f50b3009a6225670be4c026.tar.gz |
In 'bury-buffer' don't try to remove current buffer from minibuffer window
* lisp/window.el (bury-buffer): Don't try to remove current buffer
from minibuffer window.
Diffstat (limited to 'lisp/window.el')
-rw-r--r-- | lisp/window.el | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lisp/window.el b/lisp/window.el index 058e89df7c7..bf213547039 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -4732,13 +4732,16 @@ displayed there." ;; Handle case where `buffer-or-name' is nil and the current buffer ;; is shown in the selected window. (cond - ((or buffer-or-name (not (eq buffer (window-buffer))))) + ((or buffer-or-name + (not (eq buffer (window-buffer))) + ;; Don't try to delete the minibuffer window, undedicate it + ;; or switch to a previous buffer in it. + (window-minibuffer-p))) ((window--delete nil t)) (t ;; Switch to another buffer in window. (set-window-dedicated-p nil nil) (switch-to-prev-buffer nil 'bury))) - ;; Always return nil. nil)) |