[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: crash in the cvs head build of Feb 13 08:40
From: |
Kim F. Storm |
Subject: |
Re: crash in the cvs head build of Feb 13 08:40 |
Date: |
Fri, 17 Feb 2006 14:36:53 +0100 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
Sam Steingold <address@hidden> writes:
> GNU Emacs 22.0.50.5 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
> of 2006-02-15 on quant8
>
> Program received signal SIGSEGV, Segmentation fault.
> 0x080868fa in digest_single_submenu (start=Variable "start" is not available.
> ) at xmenu.c:1847
> 1847 save_wv->contents = wv;
> (gdb) list
> 1842
> 1843 wv = xmalloc_widget_value ();
> 1844 if (prev_wv)
> 1845 prev_wv->next = wv;
> 1846 else
> 1847 save_wv->contents = wv;
> 1848
> 1849 wv->lname = item_name;
> 1850 if (!NILP (descrip))
> 1851 wv->lkey = descrip;
> (gdb) p save_wv
> $1 = (widget_value *) 0x0
> (gdb) p prev_wv
> $2 = (widget_value *) 0x0
It looks like some specific sequence of menu items can
trigger the crash (don't know which).
I don't quite understand the code, but the following patch
looks like a reasonable guard against the crash.
I have no way of testing it though.
*** xmenu.c 06 Feb 2006 18:21:51 +0100 1.299
--- xmenu.c 17 Feb 2006 14:33:19 +0100
***************
*** 1843,1850 ****
wv = xmalloc_widget_value ();
if (prev_wv)
prev_wv->next = wv;
! else
save_wv->contents = wv;
wv->lname = item_name;
if (!NILP (descrip))
--- 1843,1852 ----
wv = xmalloc_widget_value ();
if (prev_wv)
prev_wv->next = wv;
! else if (save_wv)
save_wv->contents = wv;
+ else
+ first_wv->contents = wv;
wv->lname = item_name;
if (!NILP (descrip))
--
Kim F. Storm <address@hidden> http://www.cua.dk