From: Martin Rudalics Date: Sat, 28 Oct 2017 09:37:26 +0000 (+0200) Subject: Don't allow (minibuffer-window-active-p nil) to return t X-Git-Tag: emacs-26.0.91~447 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=451823b0e5e71de8949bb0eadc9ea52ec795754f;p=emacs.git Don't allow (minibuffer-window-active-p nil) to return t * lisp/window.el (minibuffer-window-active-p): Return t only if WINDOW is a live window. --- diff --git a/lisp/window.el b/lisp/window.el index 5d9409bf62c..f87294ceb15 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -2583,7 +2583,7 @@ and no others." (defun minibuffer-window-active-p (window) "Return t if WINDOW is the currently active minibuffer window." - (eq window (active-minibuffer-window))) + (and (window-live-p window) (eq window (active-minibuffer-window)))) (defun count-windows (&optional minibuf) "Return the number of live windows on the selected frame.