|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r86399 - trunk/boost/sync/detail/semaphore
From: tim_at_[hidden]
Date: 2013-10-22 16:07:08
Author: timblechmann
Date: 2013-10-22 16:07:08 EDT (Tue, 22 Oct 2013)
New Revision: 86399
URL: http://svn.boost.org/trac/boost/changeset/86399
Log:
sync: dispatch semaphores - fix wait_until
Text files modified:
trunk/boost/sync/detail/semaphore/semaphore_dispatch.hpp | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
Modified: trunk/boost/sync/detail/semaphore/semaphore_dispatch.hpp
==============================================================================
--- trunk/boost/sync/detail/semaphore/semaphore_dispatch.hpp Tue Oct 22 15:18:12 2013 (r86398)
+++ trunk/boost/sync/detail/semaphore/semaphore_dispatch.hpp 2013-10-22 16:07:08 EDT (Tue, 22 Oct 2013) (r86399)
@@ -118,7 +118,9 @@
bool priv_timed_wait(sync::detail::system_time_point const& t)
{
- return priv_timed_wait(t - sync::detail::system_time_point::now());
+ struct timespec timespec_timeout = t.get();
+ dispatch_time_t timeout = dispatch_walltime( ×pec_timeout, 0 );
+ return dispatch_semaphore_wait(m_sem, timeout) == 0;
}
template< typename TimePoint >
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