[Ekiga-devel-list] Race condition for disconnect and OnConnected "event" with 2.0.9. Patch included.



Yesterday I had Ekiga lock up. Upon connecting with gdb I found that two threads were hung trying to acquire locks. Thread 5 was processing the "OnConnected" even tfrom SipConnection, up to OpalManager and down to OpalConnection::Released. It was blocked on LockReadWrite. Thread 1, the gui thread Called Manager::ClearCall (from the disconnect button) and blocked in Call::Clear on LockReadOnly.
I couldn't find any other threads blocking in unusual states.

I have added a Mutex to GMManager that to block clearCall or OnConnected events while the other is happening and have tested for around a hundred calls without hanging, but I can't reliably reproduce this problem. If I make it through a few days without further lockups I will say it likely worked.

If this problem and fix can be confirmed it should probably be moved to Opal. I was trying to avoid having another custom package when I added these calls to GMManager.

I am attaching my patch. Please disregard the SVN information, it is from my local repository.

Attachment: ekiga-OnConnectionLock.patch.gz
Description: application/gzip



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