From d75e9881fdf648fcb6c25e344353450a7806feee Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Mon, 5 Dec 2016 11:06:55 +0100 Subject: [PATCH] Don't try to split side windows in ibuffer (Bug#25115) * lisp/ibuffer.el (ibuffer-confirm-operation-on): Don't try to split a side window (Bug#25115). --- lisp/ibuffer.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 51d7cb90755..16fbf5799ff 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -1197,7 +1197,11 @@ a new window in the current frame, splitting vertically." (ibuffer-columnize-and-insert-list names) (goto-char (point-min)) (setq buffer-read-only t)) - (let ((lastwin (car (last (window-list nil 'nomini))))) + (let ((windows (nreverse (window-list nil 'nomini))) + lastwin) + (while (window-parameter (car windows) 'window-side) + (setq windows (cdr windows))) + (setq lastwin (car windows)) ;; Now attempt to display the buffer... (save-window-excursion (select-window lastwin) -- 2.39.2