You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ta...@apache.org on 2012/10/10 16:41:47 UTC
svn commit: r1396620 -
/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/Threading.cpp
Author: tabish
Date: Wed Oct 10 14:41:47 2012
New Revision: 1396620
URL: http://svn.apache.org/viewvc?rev=1396620&view=rev
Log:
Get a copy of the thread handle before exiting the Thread mutex lock scope.
Modified:
activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/Threading.cpp
Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/Threading.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/Threading.cpp?rev=1396620&r1=1396619&r2=1396620&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/Threading.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/Threading.cpp Wed Oct 10 14:41:47 2012
@@ -162,6 +162,8 @@ namespace {
PlatformThread::notifyAll(self->condition);
+ decaf_thread_t handle = self->handle;
+
unblockThreads(self->joiners);
PlatformThread::setTlsValue(library->threadKey, NULL);
@@ -177,8 +179,6 @@ namespace {
PlatformThread::unlockMutex(self->mutex);
PlatformThread::unlockMutex(library->globalLock);
- decaf_thread_t handle = self->handle;
-
if (destroy == true) {
free(self->name);
PlatformThread::destroyMutex(self->mutex);