summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Huston <shuston@riverace.com>2012-09-06 15:13:43 +0000
committerSteve Huston <shuston@riverace.com>2012-09-06 15:13:43 +0000
commit855ebf98968f7ecb4af42e55bb9c17dbb2acf120 (patch)
tree0c71f2e3078a88ef3cee85c4a9afdefbc993c16e
parentc33cd8a349c73acf17d77b06475350aeb3925a76 (diff)
downloadATCD-855ebf98968f7ecb4af42e55bb9c17dbb2acf120.tar.gz
ChangeLogTag:Thu Sep 6 15:06:15 UTC 2012 Steve Huston <shuston@riverace.com>
-rw-r--r--ChangeLog5
-rw-r--r--ace/Log_Msg.cpp6
2 files changed, 9 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index b8c7abfd64a..cca920edb10 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Thu Sep 6 15:06:15 UTC 2012 Steve Huston <shuston@riverace.com>
+
+ * ace/Log_Msg.cpp (close): Don't try to lock/unlock the
+ ACE_LOG_MSG_INSTANCE lock if it's already been freed.
+
Wed Sep 5 20:09:09 UTC 2012 Steve Huston <shuston@riverace.com>
* ace/SSL/SSL_SOCK_Stream.inl (recv_i): Added back in logic to wait
diff --git a/ace/Log_Msg.cpp b/ace/Log_Msg.cpp
index 72499eccb0d..cc8352f9705 100644
--- a/ace/Log_Msg.cpp
+++ b/ace/Log_Msg.cpp
@@ -481,7 +481,8 @@ ACE_Log_Msg::close (void)
reinterpret_cast<ACE_thread_mutex_t *>
(ACE_OS_Object_Manager::preallocated_object
[ACE_OS_Object_Manager::ACE_LOG_MSG_INSTANCE_LOCK]);
- ACE_OS::thread_mutex_lock (lock);
+ if (lock)
+ ACE_OS::thread_mutex_lock (lock);
if (ACE_Log_Msg::key_created_)
{
@@ -513,7 +514,8 @@ ACE_Log_Msg::close (void)
ACE_Log_Msg::key_created_ = false;
}
- ACE_OS::thread_mutex_unlock (lock);
+ if (lock)
+ ACE_OS::thread_mutex_unlock (lock);
}
#endif /* (ACE_HAS_THREAD_SPECIFIC_STORAGE || ACE_HAS_TSS_EMULATION) && ACE_MT_SAFE */
}