unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Dmitry Antipov <dmantipov@yandex.ru>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 16603@debbugs.gnu.org
Subject: bug#16603: 24.3.50; Segfault when viewing a backtrace
Date: Fri, 31 Jan 2014 11:03:16 +0400	[thread overview]
Message-ID: <52EB4AB4.8040004@yandex.ru> (raw)
In-Reply-To: <878utw28pl.fsf@building.gnus.org>

On 01/31/2014 06:20 AM, Lars Ingebrigtsen wrote:

> (require 'gnus-group)
> (setq debug-on-error t)
> (gnus-read-ephemeral-emacs-bug-group 16577)
>
> Choose Rotem's article, and my Emacs crashes:

Reproduced.  With the only extra eassert:

=== modified file 'src/eval.c'
--- src/eval.c	2014-01-25 03:48:29 +0000
+++ src/eval.c	2014-01-31 06:49:49 +0000
@@ -3191,6 +3191,7 @@
  void
  record_unwind_protect (void (*function) (Lisp_Object), Lisp_Object arg)
  {
+  eassert (specpdl_ptr < specpdl + specpdl_size);
    specpdl_ptr->unwind.kind = SPECPDL_UNWIND;
    specpdl_ptr->unwind.func = function;
    specpdl_ptr->unwind.arg = arg;

I got the following backtrace:

#14 0x00000000005eafb9 in die (msg=0x70d440 "specpdl_ptr < specpdl + specpdl_size", file=0x70c498 "../../trunk/src/eval.c",
     line=3194) at ../../trunk/src/alloc.c:6761
#15 0x000000000060d987 in record_unwind_protect (function=0x605b1a <restore_stack_limits>, arg=...) at ../../trunk/src/eval.c:3194
#16 0x0000000000605c1f in call_debugger (arg=...) at ../../trunk/src/eval.c:290
#17 0x0000000000609b3b in maybe_call_debugger (conditions=..., sig=..., data=...) at ../../trunk/src/eval.c:1724
#18 0x00000000006093a5 in Fsignal (error_symbol=..., data=...) at ../../trunk/src/eval.c:1542
#19 0x00000000006094be in xsignal (error_symbol=..., data=...) at ../../trunk/src/eval.c:1579
#20 0x00000000006096e3 in signal_error (s=0x70d008 "Variable binding depth exceeds max-specpdl-size", arg=...)
     at ../../trunk/src/eval.c:1634
#21 0x000000000060a6f6 in grow_specpdl () at ../../trunk/src/eval.c:2023
#22 0x000000000060a7e3 in record_in_backtrace (function=..., args=0x7ffffff78020, nargs=1) at ../../trunk/src/eval.c:2042
#23 0x000000000060c383 in Ffuncall (nargs=2, args=0x7ffffff78018) at ../../trunk/src/eval.c:2754

IIUC this is a kind of chicken-egg problem: when we're running out of specpdl
stack, we want to run a debugger, which, in turn, needs some specpdl space to run.

Dmitry






  reply	other threads:[~2014-01-31  7:03 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-31  2:20 bug#16603: 24.3.50; Segfault when viewing a backtrace Lars Ingebrigtsen
2014-01-31  7:03 ` Dmitry Antipov [this message]
2014-01-31  8:10   ` Eli Zaretskii
2014-01-31  8:11     ` Lars Ingebrigtsen
2014-01-31  8:37       ` Eli Zaretskii
2014-02-07  3:44         ` Lars Ingebrigtsen
2014-02-07  3:50           ` Lars Ingebrigtsen
2014-02-07  5:48             ` Dmitry Antipov
2014-02-08  1:23               ` Lars Ingebrigtsen
2014-02-10  6:26                 ` Dmitry Antipov
2014-02-10  6:37                   ` Lars Ingebrigtsen
2014-02-10  9:30                     ` Dmitry Antipov
2014-02-10  9:32                       ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52EB4AB4.8040004@yandex.ru \
    --to=dmantipov@yandex.ru \
    --cc=16603@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).