From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#32850: 27.0.50; window-swap-states doesn't swap window prev/next-buffers Date: Sun, 28 Oct 2018 00:11:46 +0300 Organization: LINKOV.NET Message-ID: <87a7mz2iy5.fsf@mail.linkov.net> References: <875zyrrhk8.fsf@mail.linkov.net> <5BAD2538.1060609@gmx.at> <871s9e1syw.fsf@mail.linkov.net> <5BB082A6.6040709@gmx.at> <87o9cepxfv.fsf@mail.linkov.net> <5BB1DC5D.2070903@gmx.at> <87ftxgqcx0.fsf@mail.linkov.net> <5BBC5C61.4090901@gmx.at> <87ftx79brv.fsf@mail.linkov.net> <5BC5A536.7020603@gmx.at> <87o9bqlu7y.fsf@mail.linkov.net> <5BC98A76.9070207@gmx.at> <87in1pltn3.fsf@mail.linkov.net> <5BD2C50E.2090508@gmx.at> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1540674727 11744 195.159.176.226 (27 Oct 2018 21:12:07 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 27 Oct 2018 21:12:07 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: 32850@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Oct 27 23:12:02 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gGVsI-0002xv-Iu for geb-bug-gnu-emacs@m.gmane.org; Sat, 27 Oct 2018 23:12:02 +0200 Original-Received: from localhost ([::1]:37826 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gGVuO-0000kG-Tw for geb-bug-gnu-emacs@m.gmane.org; Sat, 27 Oct 2018 17:14:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34676) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gGVuI-0000k2-38 for bug-gnu-emacs@gnu.org; Sat, 27 Oct 2018 17:14:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gGVuE-0001k4-P3 for bug-gnu-emacs@gnu.org; Sat, 27 Oct 2018 17:14:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:41585) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gGVuE-0001jy-Jy for bug-gnu-emacs@gnu.org; Sat, 27 Oct 2018 17:14:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gGVuE-0003Qk-Bn for bug-gnu-emacs@gnu.org; Sat, 27 Oct 2018 17:14:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 27 Oct 2018 21:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32850 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 32850-submit@debbugs.gnu.org id=B32850.154067480413130 (code B ref 32850); Sat, 27 Oct 2018 21:14:02 +0000 Original-Received: (at 32850) by debbugs.gnu.org; 27 Oct 2018 21:13:24 +0000 Original-Received: from localhost ([127.0.0.1]:45843 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gGVtc-0003Pi-Kb for submit@debbugs.gnu.org; Sat, 27 Oct 2018 17:13:24 -0400 Original-Received: from giant.birch.relay.mailchannels.net ([23.83.209.68]:6005) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gGVta-0003PZ-PX for 32850@debbugs.gnu.org; Sat, 27 Oct 2018 17:13:23 -0400 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 1F1135C3650; Sat, 27 Oct 2018 21:13:21 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a3.g.dreamhost.com (unknown [100.96.35.77]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 9EBBD5C35B4; Sat, 27 Oct 2018 21:13:20 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a3.g.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.16.2); Sat, 27 Oct 2018 21:13:21 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Tart-Harbor: 29e57c1e03f73a9e_1540674800844_2673321125 X-MC-Loop-Signature: 1540674800844:1814725965 X-MC-Ingress-Time: 1540674800844 Original-Received: from pdx1-sub0-mail-a3.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a3.g.dreamhost.com (Postfix) with ESMTP id 4CA0F7F69C; Sat, 27 Oct 2018 14:13:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=linkov.net; bh=HUK6CqLVyoRxDbACUwpjHCrfCDQ=; b= sbvyEtlejMYeSmjAawgy3Ho+GYFCKn3h/NF55q+lqm/CCS8vGvqf9NBvhF/6Dj1m p4gZPemYRYOpJcFtRb6omzxtvPipx4bxG5N0hnL5eBPDOv4KIkT4W/+qoEpdqZOe Q5lgd2vF8fTlqqIwY71ZGPGtNZlJvU09HH8cKCCLxPw= Original-Received: from mail.jurta.org (m91-129-105-154.cust.tele2.ee [91.129.105.154]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a3.g.dreamhost.com (Postfix) with ESMTPSA id CE32A7F698; Sat, 27 Oct 2018 14:13:18 -0700 (PDT) X-DH-BACKEND: pdx1-sub0-mail-a3 In-Reply-To: <5BD2C50E.2090508@gmx.at> (martin rudalics's message of "Fri, 26 Oct 2018 09:41:02 +0200") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedtkedrheeggdduiedvucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuggftfghnshhusghstghrihgsvgdpffftgfetoffjqffuvfenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufhofhffjgfkfgggtgesthdtredttdertdenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucfkphepledurdduvdelrddutdehrdduheegnecurfgrrhgrmhepmhhouggvpehsmhhtphdphhgvlhhopehmrghilhdrjhhurhhtrgdrohhrghdpihhnvghtpeeluddruddvledruddthedrudehgedprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopehruhgurghlihgtshesghhmgidrrghtnecuvehluhhsthgvrhfuihiivgeptd X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:151711 Archived-At: >>> The most simple way to find out is to define such a list in window.c >>> and have 'set-window-prev-buffers' holler if the prev_buffers argument >>> is equal to that list. >> >> I can't find out how '(nil nil nil)' gets into the prev-buffers, > > Did you try what I proposed? If that doesn't catch it, I have no > idea. IIUC mark_discard_killed_buffers just removes entries from that > list, it cannot introduce any nil valued elements. > >> so to avoid the error, I propose to install this patch: > > Well this will just cache the underlying problem. But I have no good > idea how to investigate this issue any furher, so install if you like. I tried this advice: (advice-add 'set-window-prev-buffers :before (lambda (window prev-buffers) (when (member '(nil nil nil) prev-buffers) (let (frames) (mapbacktrace (lambda (evald fun args flags) (push fun frames))) (display-warning 'prev-buffers (format "%S %S" prev-buffers (nreverse frames)) :warning)))) '((name . debug))) but it still doesn't catch (nil nil nil) added to prev-buffers and here is a new backtrace: Debugger entered--Lisp error: (wrong-type-argument stringp nil) get-buffer(nil) #f(compiled-function (entry) #)((nil nil nil)) mapcar(#f(compiled-function (entry) #) (("*Help*" 1 112) (nil nil nil))) window--state-put-2(safe 737) window-state-put((... (buffer "isearch.el" ...) (prev-buffers ("*Help*" 1 112) (nil nil nil))) # safe) frameset--restore-frame(... t) frameset-restore([frameset ...] :reuse-frames t :cleanup-frames t :force-display t :force-onscreen t) desktop-restore-frameset() desktop-read() #f(compiled-function () #)() run-hooks(after-init-hook delayed-warnings-hook) command-line() normal-top-level()