From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#35784: emacs 26 crash Date: Sat, 18 May 2019 22:54:59 -0400 Message-ID: <87ftpbcfwc.fsf@gmail.com> References: <1558126467.3148.9.camel@bloodnok.com> <83ftpc9ted.fsf@gnu.org> <87zhnkc5zg.fsf@gmail.com> <87woindevp.fsf@gmail.com> <83y33393g0.fsf@gnu.org> <07948e24-aeab-9ac8-9d0d-b3a704c58b08@gmx.at> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="112703"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) Cc: 35784@debbugs.gnu.org, marc@bloodnok.com To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun May 19 04:59:48 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hSC37-000TBW-VQ for geb-bug-gnu-emacs@m.gmane.org; Sun, 19 May 2019 04:59:46 +0200 Original-Received: from localhost ([127.0.0.1]:42892 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hSC37-0001wG-1g for geb-bug-gnu-emacs@m.gmane.org; Sat, 18 May 2019 22:59:45 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:33739) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hSC2q-0001lp-2f for bug-gnu-emacs@gnu.org; Sat, 18 May 2019 22:59:29 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hSBzV-0007S6-UX for bug-gnu-emacs@gnu.org; Sat, 18 May 2019 22:56:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48242) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hSBzV-0007S2-RN for bug-gnu-emacs@gnu.org; Sat, 18 May 2019 22:56:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hSBzV-0000kR-OC for bug-gnu-emacs@gnu.org; Sat, 18 May 2019 22:56:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 May 2019 02:56:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35784 X-GNU-PR-Package: emacs Original-Received: via spool by 35784-submit@debbugs.gnu.org id=B35784.15582345102808 (code B ref 35784); Sun, 19 May 2019 02:56:01 +0000 Original-Received: (at 35784) by debbugs.gnu.org; 19 May 2019 02:55:10 +0000 Original-Received: from localhost ([127.0.0.1]:33550 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hSByf-0000jE-PA for submit@debbugs.gnu.org; Sat, 18 May 2019 22:55:10 -0400 Original-Received: from mail-it1-f169.google.com ([209.85.166.169]:40572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hSByd-0000iy-KE for 35784@debbugs.gnu.org; Sat, 18 May 2019 22:55:07 -0400 Original-Received: by mail-it1-f169.google.com with SMTP id g71so17967709ita.5 for <35784@debbugs.gnu.org>; Sat, 18 May 2019 19:55:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=BZVmdU+3g4w8h2XRtpz7/1w1r4PV+juc7uQ1hx63F9A=; b=PkBVp4opB0azf3BMNFMRj85mAimX4rlQCNNnTMckIIA9HYSjBYt5QsQVTrBSJ7SqJp qApTJ3AMsXLDluieCiAtRSdSEM5l+sOIHcMg4EOMWxwAVBUEbLZcevEU4ChFA8Fefz4y /KBWD3fz2t8tvFsOUqjvdVQUGzKkVzOoiWo0afJ7Cfr2WBguNTdzDZfUOkUAExUWr2iQ GafRy1EMeu/UsgkxtG+11tsduKMWDNcHNm2V7uzMaDHj1sDdbXFX28nAIVkQ4vEv8mHt C3xTlUI8N74jaRRXv/s4S849xIs+Pau69AMb5Z5dZ65GhxEAvNqw20hGRWUuE4eWNNIr nRmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=BZVmdU+3g4w8h2XRtpz7/1w1r4PV+juc7uQ1hx63F9A=; b=IotxWoxl6WGJsi+Ly5B8vFuJvTfKIyqUAggHwVjVTKx7SZxQGzL3s1Hlmde9xRv8xE 37H8Xi6vLyaQjtZNfMH391q0Y0LRy33cNN3liDYAgzp2H7ndGbKCeuqfqwD8IiBUzv1k 7pJUmEgWfG3gWeua7EH7LoS8heQ/7C3ah1ndlKmSW6w2tpBXeUh6zPTLNN4KyZxlpRnF NRnn+M6mS42RoGrCF04I5slP9tHjv8UYFfpfx1fhDBnVLOwUIavjzulBEq6w+5KMz1qR Wu1xjEUZ9KqK49ZOHi/kc9pAP6uDX89IwSRbEWfGtdKG0q5sXRjGtLWV9dLhkwT3rUku UvzQ== X-Gm-Message-State: APjAAAXpv5pDoFoaVP3i4CvX/Y7MrRA+I+EPJnILbi7uGxzjNS4i+rm5 Ol5HFTzxPbucF8B6YNlFJso= X-Google-Smtp-Source: APXvYqyaBseWHQuRj2YQM5JSxE7KqDJngaGFi+Ig0Qs3UgS9sFgU2cpcQ2RkX9TxX+cZpdFdNnadWA== X-Received: by 2002:a24:6292:: with SMTP id d140mr8630209itc.132.1558234501967; Sat, 18 May 2019 19:55:01 -0700 (PDT) Original-Received: from minid (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.gmail.com with ESMTPSA id m64sm2369964itg.4.2019.05.18.19.55.00 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 18 May 2019 19:55:01 -0700 (PDT) In-Reply-To: <07948e24-aeab-9ac8-9d0d-b3a704c58b08@gmx.at> (martin rudalics's message of "Sat, 18 May 2019 19:30:50 +0200") 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: 209.51.188.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:159521 Archived-At: >>> #2 0x000000000061849e in die (msg=0x743f3f "BUFFERP (a)", >>> file=0x743f36 "buffer.h", line=914) at alloc.c:7406 >>> #3 0x00000000005802b3 in XBUFFER (a=0) at buffer.h:914 >>> #4 0x0000000000468bb3 in mark_window_display_accurate_1 (w=0x558e410, >>> accurate_p=false) at xdisp.c:14754 >>> b = 0x7ffe74b60e40 >>> #5 0x0000000000468ffd in mark_window_display_accurate >>> (window=89711637, accurate_p=false) at xdisp.c:14811 >>> w = 0x558e410 >>> #6 0x00000000004bbe06 in Fforce_window_update (object=89711637) at >>> window.c:3643 >>> w = 0x558e410 >> >> This seems to imply that we are trying to update a non-leaf window, >> something that should never happen. There's no Lisp-level backtrace, >> so it's hard to tell what Lisp called force-window-update, and how the >> window in question became non-leaf, but maybe some crazy Lisp hook >> switched windows behind redisplay's back or something. > > I'd rather guess that this is the result of 'kill-buffer' called from > 'delete-frame-functions' or 'delete-frame' called from > 'kill-buffer-hook'. But at the moment I can't reproduce the bug here > any more. The Lisp backtrace is: "force-window-update" (0xffffd640) 0x2f61c80 Lisp type 3 "mapc" (0xffffd960) "k-tabbar2::pc-handle-queued-updates" (0xffffdb00) "k-tabbar2::post-command-fn" (0xffffddf0) I think the problem is just that the Lisp code is calling force-window-update on a deleted window. At least, I can trigger the crash with (let ((w (split-window))) (delete-window w) (force-window-update w)) And the following fixes it: --- i/src/window.c +++ w/src/window.c @@ -4089,7 +4089,7 @@ displaying that buffer. */) return Qt; } - if (WINDOWP (object)) + if (WINDOW_LIVE_P (object)) { struct window *w = XWINDOW (object); mark_window_display_accurate (object, false);