24 Mar
2015
24 Mar
'15
10:40 p.m.
On 24/03/2015 22:28, Fu ji wrote:
Condition variable can be a really good solution to my problem, I have only problem with WaitForMultipleObjects because with cond_var I have to check all "events" in loop with cond.timed_wait. There is a better solution ?
If the events are intended to signal that data is available somewhere, then you could consider replacing them with futures instead, which can supply the data at the same time. There is a way to wait for one or all of a set of multiple futures, although not with a timeout.