From 4596c725c70044c6935d507e27cbfc0a80eebe4b Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Mon, 22 Oct 2001 18:51:10 +0000 Subject: [PATCH] (compilation-set-window-height): Select old window only if it's still live. --- lisp/ChangeLog | 5 +++++ lisp/progmodes/compile.el | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 526faad294e..1a51430415f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2001-10-22 Gerd Moellmann + + * progmodes/compile.el (compilation-set-window-height): Select + old window only if it's still live. + 2001-10-22 Eli Zaretskii * textmodes/sgml-mode.el (sgml-mode-map): Bind 8-bit codes above diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 769c356449f..37b834b510d 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -877,7 +877,10 @@ exited abnormally with code %d\n" (select-window window) (enlarge-window (- compilation-window-height (window-height)))) - (select-window w)))))) + ;; The enlarge-window above may have deleted W, if + ;; compilation-window-height is large enough. + (when (window-live-p w) + (select-window w))))))) (defvar compilation-minor-mode-map (let ((map (make-sparse-keymap))) -- 2.39.2