Current xserver head segfault

Peter Hutterer peter at cs.unisa.edu.au
Thu Jun 19 16:17:41 PDT 2008


On Thu, Jun 19, 2008 at 06:20:04PM +0200, Lukas Hejtmanek wrote:
> Hello,
> 
> I tried to run latest Xserver and got the following segfault after any
> keypres:
> (gdb) c
> Continuing.
> 
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 0x7fb1af89b6e0 (LWP 15744)]
> 0x00007fb1ad64cc48 in ?? () from /lib/libc.so.6
> (gdb) where
> #0  0x00007fb1ad64cc48 in ?? () from /lib/libc.so.6
> #1  0x00007fb1ad64db6e in realloc () from /lib/libc.so.6
> #2  0x00000000004f788b in Xrealloc (ptr=0x2b1, amount=0) at utils.c:1387
                                          ^^^^^
                                          looks busted
> #3  0x000000000055330a in XkbCopyKeymap (src=0x18c5790, dst=0x18c6340,
> sendNotifies=1) at xkbUtils.c:1236
> #4  0x000000000053a20b in DeepCopyDeviceClasses (from=0x1839520, to=0x1837e70)
> at exevents.c:225
> #5  0x000000000053b271 in UpdateDeviceState (device=0x2b1, xE=0x18db7a0,
                                                      ^^^^^
                                                      looks busted.
> #6  0x000000000053b612 in ProcessOtherEvent (xE=0x18db7a0, device=0x1839520,
> count=1) at exevents.c:1001

for some reason your memory looks corrupted between POE and UDS. I don't know
if that's a result of optimization or actual corruption. Can you recompile
with -O0 and see if the problem persists, and if the backtrace changes?

Checking the source - POE doesn't touch the device argument, so it should not
change between POE and UDS.
And the pointer passed into realloc should never be invalid, since it was
calloc'd and then alloc'd, both of which should guarantee either NULL or a
valid memory address.

Cheers,
  Peter



More information about the xorg mailing list