Thank you for the bug report, Thomas!
Ar an seachtú lá déag de mí na Nollaig, scríobh Thomas Mittelstaedt:
> Just had a little crash
>
> Fatal error: assertion failed, file eval.c, line 1489, Attempt to call
> Lisp code from within redisplay without being properly wrapped
>
> Fatal error (6).
>
> [...]
>
> Lisp backtrace follows:
>
> # (unwind-protect ...)
> # (unwind-protect ...)
> # (unwind-protect ...)
> # (unwind-protect ...)
> # (unwind-protect ...)
> # (unwind-protect ...)
> # (unwind-protect ...)
> # bind (did)
> G19744(65717)
This a call to the lambda on line 548 of dialog.el. The lambda was on
delete-frame-hook, so error means the frame in question was deleted from
within redisplay.
> # (unwind-protect ...)
> # bind (inhibit-quit)
> # (unwind-protect ...)
> # (unwind-protect ...)
>
> [...]
>
> (gdb) bt
> #0 0xc01ffd40 in kill () from /usr/lib/libc.2
> #1 0x000e69fc in fatal_error_signal (sig=6) at emacs.c:3800
> #2 <signal handler called>
> #3 0xc01e494c in fflush () from /usr/lib/libc.2
> #4 0x002afa00 in do_symval_forwarding (valcontents=0, buffer=0x0,
> console=0x402aa924) at symbols.c:1083
> #5 0x40cfe5d4 in ?? ()
> #6 0x40cfe5d4 in ?? ()
> Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Shame there’s not a better C stack available--I can’t find a place where
this will happen from a few minutes’ looking.
Anyway, given that we know it’s happened, and that the _trapping_problems
code should prevent it happening in the future, does anyone have any
objections to this?
diff -r dfd878799ef0 src/frame.c
--- a/src/frame.c Fri Dec 14 14:25:04 2007 +0100
+++ b/src/frame.c Mon Dec 17 16:33:35 2007 +0100
@@ -1540,7 +1540,8 @@ delete_frame_internal (struct frame *f,
user code there could do any number of dangerous things, including
signalling an error. */
- va_run_hook_with_args (Qdelete_frame_hook, 1, frame);
+ va_run_hook_with_args_trapping_problems
+ (Qframe, Qdelete_frame_hook, 1, frame);
if (!FRAME_LIVE_P (f)) /* Make sure the delete-frame-hook didn't */
{ /* go ahead and delete anything. */
@@ -1553,7 +1554,8 @@ delete_frame_internal (struct frame *f,
signal an error. */
if (XINT (Flength (DEVICE_FRAME_LIST (d))) == 1)
{
- va_run_hook_with_args (Qdelete_device_hook, 1, device);
+ va_run_hook_with_args_trapping_problems
+ (Qdevice, Qdelete_device_hook, 1, device);
if (!FRAME_LIVE_P (f)) /* Make sure the delete-device-hook didn't */
{ /* go ahead and delete anything. */
UNGCPRO;
@@ -1562,7 +1564,8 @@ delete_frame_internal (struct frame *f,
if (XINT (Flength (CONSOLE_DEVICE_LIST (con))) == 1)
{
- va_run_hook_with_args (Qdelete_console_hook, 1, console);
+ va_run_hook_with_args_trapping_problems
+ (Qconsole, Qdelete_console_hook, 1, console);
if (!FRAME_LIVE_P (f)) /* Make sure the delete-console-hook didn't */
{ /* go ahead and delete anything. */
UNGCPRO; |