gEDA-dev: Another autosave crash....

Peter C.J. Clifton pcjc2 at cam.ac.uk
Sun Sep 3 07:03:24 EDT 2006


On Sep 2 2006, Ales Hvezda wrote:

>[snip]
>>I can confirm that CVS version of gschem tends to crash if you leave it
>>running idle for a couple of hours (I often leave my workstation in the
>>middle of my work and when I come back I usually find gschem crashed).
>
>	:-(
>
>	There is a race between the deletion of a page (or other
>user activites) and the auto save mechanism.  I am in the process of
>adding a mutex to protect/fix this problem.  The code within libgeda and
>gschem was never intended to be thread safe, so I'm not particularly
>thrilled about adding a mutex, but I don't think I have any choice.
>I'll send out an e-mail once I have checked in a fix.
>
>								-Ales

Ok, sounds similar to what we saw when the autosave code would crash 
occasionally as the program exits.

The autosave code isn't run as a thread, is it? I guess this means that its 
not a mutex in the sense of threaded code, but instead more of a flag to 
let the autosave code know if the internal state is suitable to be saved.

Why does the autosave code crash out when gschem is idle? (I realise that 
this is when the autosave is called, but what is it racing with at this 
point?) At what point is the memory pointer which it segfaults on becoming 
invalid?

Regards

Peter Clifton



More information about the geda-dev mailing list