Re: [Tuxpaint-devel] Kaleidoscope crash
An award-winning drawing program for children of all ages
Brought to you by:
wkendrick
|
From: Albert C. <aca...@gm...> - 2007-12-01 02:10:09
|
If using gdb, then use Electric Fence at the same time. Without that, the crash is likely to be in unrelated code. The bad code overflows a buffer, but this doesn't cause an immediate crash. Later, good code calls malloc() and gets a crash because malloc() walks a corrupt list. Electric Fence puts unmapped memory after each allocation, causing crashes to be immediate and making gdb useful. You can: a. link with -lefence b. set LD_PRELOAD to the name of the libefence *.so c. use the "ef" program, which sets LD_PRELOAD for you See "man efence" for extra info; setting the alignment to 0 would be a good idea. There are many things this won't spot though. Valgrind is probably the better tool. |