From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#39977: 28.0.50; Unhelpful stack trace Date: Fri, 13 Mar 2020 11:55:26 +0200 Message-ID: <83imj88tpt.fsf@gnu.org> References: <83zhcs80e5.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="85241"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 39977@debbugs.gnu.org To: enometh@meer.net, martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Mar 13 10:56:13 2020 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 1jCh35-000LwM-1H for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 13 Mar 2020 10:56:11 +0100 Original-Received: from localhost ([::1]:56308 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jCh34-0001oc-45 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 13 Mar 2020 05:56:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50166) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jCh2x-0001nT-GN for bug-gnu-emacs@gnu.org; Fri, 13 Mar 2020 05:56:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jCh2w-0004NX-EM for bug-gnu-emacs@gnu.org; Fri, 13 Mar 2020 05:56:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52213) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jCh2w-0004NR-Ao for bug-gnu-emacs@gnu.org; Fri, 13 Mar 2020 05:56:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jCh2w-0003l3-Aw for bug-gnu-emacs@gnu.org; Fri, 13 Mar 2020 05:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 13 Mar 2020 09:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39977 X-GNU-PR-Package: emacs Original-Received: via spool by 39977-submit@debbugs.gnu.org id=B39977.158409333714412 (code B ref 39977); Fri, 13 Mar 2020 09:56:02 +0000 Original-Received: (at 39977) by debbugs.gnu.org; 13 Mar 2020 09:55:37 +0000 Original-Received: from localhost ([127.0.0.1]:58186 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCh2X-0003kN-9f for submit@debbugs.gnu.org; Fri, 13 Mar 2020 05:55:37 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:34621) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCh2W-0003kC-Js for 39977@debbugs.gnu.org; Fri, 13 Mar 2020 05:55:36 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:54324) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1jCh2Q-0003ii-UX; Fri, 13 Mar 2020 05:55:30 -0400 Original-Received: from [176.228.60.248] (port=2738 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jCh2O-0002ud-IX; Fri, 13 Mar 2020 05:55:29 -0400 In-Reply-To: <83zhcs80e5.fsf@gnu.org> (message from Eli Zaretskii on Sat, 07 Mar 2020 20:50:42 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:177264 Archived-At: Ping! Can you please try the proposed patch? Martin, any thoughts or comments about this? > Date: Sat, 07 Mar 2020 20:50:42 +0200 > From: Eli Zaretskii > Cc: 39977@debbugs.gnu.org > > > From: Madhu > > Date: Sat, 07 Mar 2020 23:13:16 +0530 > > > > Thanks Eli, Following up on the emacs-devel message, I recompiled emacs > > and get substantially the same stack trace. This is with my ~/.emacs and > > all my local customizations loaded. > > > > when evaluating a form in a sly lisp buffer with > > (break) > > M-x sly-eval-last-sexp > > pops up a sly debug window in a new frame > > quitting the window (and frame) tries to select the previous window > > and the crash apparently happens at this point. I'm attaching the > > backtraces as attachments > > > > With a little guidance I expect to be able to investigate this further > > Thanks. Please try the patch below, and tell if it makes the crash > go away. > > diff --git a/src/window.c b/src/window.c > index 8cdad27..863fac4 100644 > --- a/src/window.c > +++ b/src/window.c > @@ -541,8 +541,11 @@ select_window (Lisp_Object window, Lisp_Object norecord, > else > redisplay_other_windows (); > > - sf = SELECTED_FRAME (); > - if (XFRAME (WINDOW_FRAME (w)) != sf) > + if (FRAMEP (selected_frame) && FRAME_LIVE_P (XFRAME (selected_frame))) > + sf = XFRAME (selected_frame); > + else > + sf = NULL; > + if (!sf || XFRAME (WINDOW_FRAME (w)) != sf) > { > fset_selected_window (XFRAME (WINDOW_FRAME (w)), window); > /* Use this rather than Fhandle_switch_frame > > > >