|
Boost-Commit : |
From: anthony_at_[hidden]
Date: 2008-05-21 17:10:45
Author: anthonyw
Date: 2008-05-21 17:10:45 EDT (Wed, 21 May 2008)
New Revision: 45625
URL: http://svn.boost.org/trac/boost/changeset/45625
Log:
Use lock_guard<> instead of unique_lock<> internally. Clear out generations after notify_all, as they're all notified
Text files modified:
trunk/boost/thread/win32/condition_variable.hpp | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
Modified: trunk/boost/thread/win32/condition_variable.hpp
==============================================================================
--- trunk/boost/thread/win32/condition_variable.hpp (original)
+++ trunk/boost/thread/win32/condition_variable.hpp 2008-05-21 17:10:45 EDT (Wed, 21 May 2008)
@@ -206,7 +206,7 @@
{
if(detail::interlocked_read_acquire(&total_count))
{
- boost::mutex::scoped_lock internal_lock(internal_mutex);
+ boost::lock_guard<boost::mutex> internal_lock(internal_mutex);
if(!total_count)
{
return;
@@ -227,7 +227,7 @@
{
if(detail::interlocked_read_acquire(&total_count))
{
- boost::mutex::scoped_lock internal_lock(internal_mutex);
+ boost::lock_guard<boost::mutex> internal_lock(internal_mutex);
if(!total_count)
{
return;
@@ -239,6 +239,7 @@
{
(*it)->release(detail::interlocked_read_acquire(&(*it)->waiters));
}
+ generations.clear();
wake_sem=detail::win32::handle(0);
}
}
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk