摘要:
条件变量是一种同步机制,允许线程挂起,直到共享数据上的某些条件得到满足。条件变量上的基本操作有:触发条件(当条件变为 true 时);等待条件,挂起线程直到其他线程触发条件 while ()为什么是while而不是if?因为可能会有虚假唤醒的问题。 "This means that when you wait on a condition variable, the wait may (o... 阅读全文
posted @ 2018-01-07 10:41
花老🐯
阅读(268)
评论(0)
推荐(0)

浙公网安备 33010602011771号