GNU bug report logs - #47244
28.0.50; SIGSEGV in long-runnning Emacs

Previous Next

Package: emacs;

Reported by: Michael Welsh Duggan <md5i <at> md5i.com>

Date: Thu, 18 Mar 2021 15:40:01 UTC

Severity: normal

Found in version 28.0.50

Done: Michael Welsh Duggan <mwd <at> md5i.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: martin rudalics <rudalics <at> gmx.at>
To: Michael Welsh Duggan <mwd <at> md5i.com>, Michael Welsh Duggan <mwd <at> cert.org>
Cc: "47244 <at> debbugs.gnu.org" <47244 <at> debbugs.gnu.org>, "schwab <at> linux-m68k.org" <schwab <at> linux-m68k.org>
Subject: bug#47244: 28.0.50; SIGSEGV in long-runnning Emacs
Date: Thu, 8 Apr 2021 17:48:23 +0200
> Okay, close, but not quite.  What seems to be happening is this:
> list_windows()

This is a local rewrite.  You really intend window_list() here.  Right?

> 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.

OK.  If you really get out of this after the first

	  Vwindow_list = nconc2 (Vwindow_list, arglist);

then we have one recorded frame, the length of Vwindow_list is 2 but we
did not record it in the earlier length-based experiment and the 2 won't
show up in the list of lengths.  So the explanation is valid and a bit
gruesome too.  This might hit us anywhere ...

> 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.
>
> 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?

Try with

  block_input ();
  ...
  unblock_input ();

around it.

martin




This bug report was last modified 4 years and 28 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.