[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: stack overflow while using sml-mode.el

From: Eli Zaretskii
Subject: Re: stack overflow while using sml-mode.el
Date: Mon, 23 Oct 2000 13:45:42 +0200 (IST)

On 22 Oct 2000, Colin Walters wrote:

> I'm having a strange problem where Emacs will overflow the stack in
> alloc.c, while using sml-mode.el, by Stefan Monnier.

How do you know it's a stack overflow?  In the data you presented from
the GDB session, I don't see anything that would indicate it's a stack
problem; it could be just a SIGSEGV.

> (gdb) p ptr
> $6 = (struct Lisp_String *) 0x8366eb4
> (gdb) xstring
> Argument to arithmetic operation not a number or boolean.
> (gdb) p objptr
> $7 = (int *) 0x82f2c7c
> (gdb) p *objptr
> $8 = 943091380
> (gdb) xtype
> Lisp_String
> 0
> (gdb)      
> (Am I using the "xstring" macro correctly?)

No.  You need to either do this:

 (gdb) p ptr
 $6 = (struct Lisp_String *) 0x8366eb4
 (gdb) p *(struct Lisp_String *) 0x8366eb4

or this:

 (gdb) p *objptr
 $8 = 943091380
 (gdb) xtype
 (gdb) xstring

In other words, "xstring" works on Lisp_Object objects, not on C

(And, btw, "xstring" is a user-defined command, not a macro.)

> I still have this gdb session running, if more information is needed.

Can you find out what exactly was Emacs doing when it crashed (apart
of GC)?  Was it, per chance, matching a complicated regexp?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]