From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Michael Welsh Duggan Newsgroups: gmane.emacs.bugs Subject: bug#47244: 28.0.50; SIGSEGV in long-runnning Emacs Date: Thu, 08 Apr 2021 12:05:57 -0400 Message-ID: References: <87im5ofp3z.fsf@md5i.com> <870479cc-efd3-3a19-98a3-1d7a8b9346e8@gmx.at> <79cfe67d-3a2c-952d-7c51-20e8a4859380@gmx.at> <87czv6q1f8.fsf@md5i.com> <233daa4b-ca64-955f-2612-49a0503b1938@gmx.at> <8735w2p8oc.fsf@md5i.com> <5181da75-e80d-22e0-bdcb-a0ffdc1bac6a@gmx.at> <5c4e5857-6a76-b8e8-204b-b4a855e95a16@gmx.at> <8f4516d5-1080-71bb-7da7-acf7832d5529@gmx.at> <87r1jlvnrc.fsf@md5i.com> <871rbkn6op.fsf@md5i.com> <83pmz493ag.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="31080"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: Michael Welsh Duggan , "schwab@linux-m68k.org" , "47244@debbugs.gnu.org" <47244@debbugs.gnu.org> To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Apr 08 18:16:42 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 1lUXKj-0007w2-CT for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 08 Apr 2021 18:16:41 +0200 Original-Received: from localhost ([::1]:48952 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lUXKi-0003nI-De for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 08 Apr 2021 12:16:40 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:42720) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lUXBO-0002gx-Gy for bug-gnu-emacs@gnu.org; Thu, 08 Apr 2021 12:07:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:36502) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lUXBO-0002cW-5T for bug-gnu-emacs@gnu.org; Thu, 08 Apr 2021 12:07:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lUXBN-0000xw-Uf for bug-gnu-emacs@gnu.org; Thu, 08 Apr 2021 12:07:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Welsh Duggan Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 08 Apr 2021 16:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47244 X-GNU-PR-Package: emacs Original-Received: via spool by 47244-submit@debbugs.gnu.org id=B47244.16178979703647 (code B ref 47244); Thu, 08 Apr 2021 16:07:01 +0000 Original-Received: (at 47244) by debbugs.gnu.org; 8 Apr 2021 16:06:10 +0000 Original-Received: from localhost ([127.0.0.1]:48047 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lUXAX-0000wl-RL for submit@debbugs.gnu.org; Thu, 08 Apr 2021 12:06:10 -0400 Original-Received: from veto.sei.cmu.edu ([147.72.252.17]:52550) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lUXAW-0000wG-2N for 47244@debbugs.gnu.org; Thu, 08 Apr 2021 12:06:09 -0400 Original-Received: from delp.sei.cmu.edu (delp.sei.cmu.edu [10.64.21.31]) by veto.sei.cmu.edu (8.14.7/8.14.7) with ESMTP id 138G61cX006243; Thu, 8 Apr 2021 12:06:01 -0400 DKIM-Filter: OpenDKIM Filter v2.11.0 veto.sei.cmu.edu 138G61cX006243 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cert.org; s=yc2bmwvrj62m; t=1617897961; bh=ryMDhmtB62YOxMu/YWVArVURjZWqzo/rpt7TYDkPT50=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=PU6JsedayF30Eu4EeXGzV7GGK2uPQRHK4aYN0Q0/M3XdFYASnNLAAHI5W++t7VyCs 6GzRrV3nR5wnlC6fD5OIX9gDfslw8+RuqqCD6R+FXUMMQcYAS/Oc9GA2djynL3Nmb1 lyoD64KYR3B4MrmJGOsrHY9f0RVrz7gWXaFbcHxE= Original-Received: from lx-birch.ad.sei.cmu.edu (lx-birch.ad.sei.cmu.edu [10.64.53.120]) by delp.sei.cmu.edu (8.14.7/8.14.7) with ESMTP id 138G5wQ1042257; Thu, 8 Apr 2021 12:05:58 -0400 Original-Received: from lx-birch.ad.sei.cmu.edu (localhost [127.0.0.1]) by lx-birch.ad.sei.cmu.edu (8.14.7/8.14.7) with ESMTP id 138G5wdH007631; Thu, 8 Apr 2021 12:05:58 -0400 Original-Received: (from mwd@localhost) by lx-birch.ad.sei.cmu.edu (8.14.7/8.14.7) id 138G5vkX007628; Thu, 8 Apr 2021 12:05:57 -0400 X-Authentication-Warning: lx-birch.ad.sei.cmu.edu: mwd set sender to mwd@cert.org using -f In-Reply-To: <83pmz493ag.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 8 Apr 2021 11:58:15 -0400") 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:203738 Archived-At: Eli Zaretskii writes: >> From: Michael Welsh Duggan >> Date: Thu, 08 Apr 2021 11:21:10 -0400 >> Cc: Michael Welsh Duggan , >> "schwab@linux-m68k.org" , >> "47244@debbugs.gnu.org" <47244@debbugs.gnu.org> >> >> Okay, close, but not quite. What seems to be happening is this: >> list_windows() is called while Vwindow_list is nil, and the if branch is >> taken. Something causes list_windows() to exit without reaching the end >> of the if block. This leaves Vwindow_list partially created. The next >> time list_windows() is called it returns the partially created list. >> >> To determine this I put a breakpoint at the beginning of the if block >> that sets a gdb convenience variable called $in_list_windows to one and >> continues. I put a breakpoint at the end of that block that sets it to >> zero and continues. I put a third condition breakpoint at the entrance >> to list_windows() that only triggers if $in_list_windows is one. This >> triggered with the included backtrace. > > I guess you mean window_list instead of list_windows? Yes, sorry. >> Once again, the state triggered when, due to the VPN state changing, a >> background gnus demon hung trying to fetch mail. The trigger was me >> hitting C-g twice rapidly in succession to regain interactivity. >> >> Can anyone recommend a means to check if this my theory is true? Does >> list_windows() need to be protected against quit? > > Set a breakpoint in 'quit' and disable it. Set another breakpoint at > entry to 'window_list' that enables the breakpoint in 'quit', then > another breakpoint at exit which disables the breakpoint in 'quit'. > Then wait for the breakpoint in 'quit' to break during your recipe. > > Perhaps also do the same with a breakpoint in Fthrow. Good idea! I'm going to try that. > >> #26 0x000055555583108e in print_error_message >> (data=XIL(0x55555732d343), stream=XIL(0x30), context=0x7ffff2c64148 >> "", caller=XIL(0)) at ../../master/src/print.c:944 >> error_conditions = XIL(0x7ffff2c2da13) >> errname = XIL(0xb820) >> errmsg = make_fixnum(23456248526235) >> file_error = XIL(0x7fffffffd4c0) >> tail = XIL(0x30) > > What error message does this attempt to print? (gdb) p errname $8 = XIL(0xb820) (gdb) xtype Lisp_Symbol (gdb) xpr Lisp_Symbol $9 = (struct Lisp_Symbol *) 0x555555e6e8a0 "quit" (gdb) p errmsg $10 = XIL(0x55555571d654) (gdb) xpr Lisp_String $11 = (struct Lisp_String *) 0x55555571d650 0 (gdb) p error_conditions $14 = XIL(0x7ffff2c2da33) (gdb) xpr Lisp_Cons $15 = (struct Lisp_Cons *) 0x7ffff2c2da30 { u = { s = { car = XIL(0xb820), u = { cdr = XIL(0), chain = 0x0 } }, gcaligned = 0x20 } } (gdb) xlist $16 = 0xb820 Lisp_Symbol $17 = (struct Lisp_Symbol *) 0x555555e6e8a0 "quit" --- nil -- Michael Welsh Duggan (mwd@cert.org)