-
- Downloads
Added timeout parameter to semaphore::wait()
Added a timeout parameter to semaphore::wait(), which defaults to no timeout. semaphore:wait() is now a boolean, just like trywait(), and likewise can return false when the semaphore has not actually been decremented but rather we had a timeout. Because we need the mutex again after the wait, I replaced the "with_lock" mechanism by the better-looking lock_guard and mutex parameter to wait_until.
Please register or sign in to comment