Hide Forgot
Description of problem: There is a race condition between qpid::client::SessionImpl::waitForCompletion and qpid::client::SessionImpl::~SessionImpl. If one thread is waiting for a completion and another thread causes the destructor for the session to be invoked, the destructor can abort the client if waitForCompletion is still holding the state mutex. The reason this occurs is because waitForCompletion is not holding a Waiter::ScopedWait, so the destructor completes while the mutex is still being held. This was discovered when testing connection loss and recovery. Version-Release number of selected component (if applicable): qpid-cpp-client-0.7.946106-28_ptc_hotfix_5_v2.el5 How reproducible: Hard to reproduce, but have had several crashes Actual results: The client application aborts due to a failed assertion Expected results: The client application should continue to function Additional info: See attached backtrace between the two competing threads.
Created attachment 512527 [details] Stack backtrace from crash
Created attachment 512528 [details] Suggested patch
See https://issues.apache.org/jira/browse/QPID-3355 for details and proposed patch
I believe the fix for this is http://svn.apache.org/viewvc?rev=1145935&view=rev, patch attached to QPID-3355 has also been applied however.
This is in the 0.14 rebase