Re: NEWS on 1.6.0, crash fix... semi-fix (if you create and quickly delete a window sawfish will segfault)

Am Freitag, den 09.10.2009, 22:05 +0200 schrieb Janek Kozicki:
> Timo Korvola said:     (by the date of Thu, 8 Oct 2009 00:52:51 +0300)
> > My approach there is not mutually exclusive with Janek's, which 
> > consisted of adding more error checking to add_window.  To test my patch 
> > one should try to trip Sawfish on errors as hard as possible, so it is 
> > best not to add any error checking before gaining reasonable confidence 
> > that my patch works.  However, eventually some more intermediate error 
> > checking in add_window would perhaps be good, although not quite as much 
> > as in Janek's patch should be necessary.
> Hi, so I did extensive testing.
> With Timo's patch I did 130 tries and no crash! However Following valgrind error
> occurs once, at the FIRST try:
> ==11117== Conditional jump or move depends on uninitialised value(s)
> ==11117==    at 0x4E5EFE3: vm (lispmach.h:850)

lispmach.h ... bah, I hate this file. Just get a look on it (or even
worser: try to compile with it using -ansi -Wall)

XXX needs rewrite before 1.0.0

> ==11117==    by 0x4E5DE8C: inline_apply_bytecode (lispmach.h:505)
> ==11117==    by 0x4E5EC2B: vm (lispmach.h:751)
> ==11117==    by 0x4E5DE8C: inline_apply_bytecode (lispmach.h:505)
> ==11117==    by 0x4E646F0: rep_apply_bytecode (lispmach.c:81)
> ==11117==    by 0x4E53CE9: apply (lisp.c:1710)
> ==11117==    by 0x4E53F98: Ffuncall (lisp.c:1776)
> ==11117==    by 0x4E5CC27: Fcall_hook (lispcmds.c:1934)
> ==11117==    by 0x42A121: Fcall_window_hook (windows.c:1374)
> ==11117==    by 0x42B03F: add_window (windows.c:534)
> ==11117==    by 0x415B0F: map_request (events.c:751)
> ==11117==    by 0x414501: inner_handle_input (events.c:1406)
> ==11117== 
> We can see that windows.c:534 calls Fcall_window_hook() with
> an uninitialised argument. So I tired adding my safegueard just before
> this call, and so then I tried 130 times, and valgrind didn't produce
> any error at all! And no crash too. Instead sawfish was printing this
> error message:
>   warning: failed to allocate a window

squashing this one would be good, too, but it's just a warning, so it's
not that tragic.

> Which is much better than valgrind reporting errors :)
> So I guess that attached patch against 1.5.0 is the best option.
> PS: As a side note - the XGrabServer method didn't work at all.
> Instant crash on first try, even though XGrabServer() indeed grabs
> server! I tested that it indeed grabs server with simple attached program :)

will apply to sawfish-1.5 [BRANCH] and 1.6.0 [HEAD].

Btw 1.5.3 (the last planned 1.5x release) will be in stores around
beginning of November.


Attachment: signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil

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