From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#52491: 28.0.90; Regression in window deletion with minibuffer Date: Tue, 21 Dec 2021 10:05:52 +0200 Organization: LINKOV.NET Message-ID: <86a6gucrhb.fsf@mail.linkov.net> References: <865yrqsxmu.fsf@mail.linkov.net> <865yro7csh.fsf@mail.linkov.net> <83h7b8fngd.fsf@gnu.org> <86v8zo4bma.fsf@mail.linkov.net> <83fsqsfh8i.fsf@gnu.org> <86tuf73aen.fsf@mail.linkov.net> <83h7b7e8t2.fsf@gnu.org> <4318fa2c-0127-4a14-f65e-399b5c097028@gmx.at> <86sfupu8xi.fsf@mail.linkov.net> <9c2cbe85-b1a0-f147-69c8-0f26ab2e7c4d@gmx.at> <86wnk0frfj.fsf@mail.linkov.net> <0a55b1f4-dd66-62ed-591a-75438033e357@gmx.at> <86a6gwe9kl.fsf@mail.linkov.net> <9373956f-4999-4e0c-96f9-626f30d4cdb9@gmx.at> <83mtkv18xz.fsf@gnu.org> <1cba0ff2-3345-d2f4-f9a3-a61c79487a50@gmx.at> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="38746"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) Cc: 52491@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Dec 21 09:14:13 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mzaHk-0009of-4S for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 21 Dec 2021 09:14:12 +0100 Original-Received: from localhost ([::1]:57322 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mzaHj-0000UE-1n for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 21 Dec 2021 03:14:11 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:42300) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mzaEg-0004gv-Tl for bug-gnu-emacs@gnu.org; Tue, 21 Dec 2021 03:11:05 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40707) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mzaEg-0001Ma-L1 for bug-gnu-emacs@gnu.org; Tue, 21 Dec 2021 03:11:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mzaEg-0006n2-H9 for bug-gnu-emacs@gnu.org; Tue, 21 Dec 2021 03:11:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 21 Dec 2021 08:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52491 X-GNU-PR-Package: emacs Original-Received: via spool by 52491-submit@debbugs.gnu.org id=B52491.164007424526049 (code B ref 52491); Tue, 21 Dec 2021 08:11:02 +0000 Original-Received: (at 52491) by debbugs.gnu.org; 21 Dec 2021 08:10:45 +0000 Original-Received: from localhost ([127.0.0.1]:52247 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mzaEP-0006m4-Ig for submit@debbugs.gnu.org; Tue, 21 Dec 2021 03:10:45 -0500 Original-Received: from relay8-d.mail.gandi.net ([217.70.183.201]:59393) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mzaEN-0006lm-Fq for 52491@debbugs.gnu.org; Tue, 21 Dec 2021 03:10:44 -0500 Original-Received: (Authenticated sender: juri@linkov.net) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id 57E8C1BF20A; Tue, 21 Dec 2021 08:10:35 +0000 (UTC) In-Reply-To: <1cba0ff2-3345-d2f4-f9a3-a61c79487a50@gmx.at> (martin rudalics's message of "Mon, 20 Dec 2021 19:08:40 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:222856 Archived-At: >> Do you think this is safe enough to install on the release branch? > > Probably not. I'm confused as to which posts made it today to the list. > A correct patch is attached now and should be safe for Emacs 28. > > @@ -5167,7 +5167,10 @@ quit-restore-window > (cond > ;; First try to delete dedicated windows that are not side windows. > ((and dedicated (not (eq dedicated 'side)) > - (window--delete window 'dedicated (eq bury-or-kill 'kill)))) > + (window--delete window 'dedicated (eq bury-or-kill 'kill)) > + (or (and (window-live-p (nth 2 quit-restore)) > + (select-window (nth 2 quit-restore))) > + t))) Or maybe simply: ((and dedicated (not (eq dedicated 'side)) (window--delete window 'dedicated (eq bury-or-kill 'kill))) ;; If the previously selected window is still alive, select it. (when (window-live-p (nth 2 quit-restore)) (select-window (nth 2 quit-restore))))