Reputation:
Is it possible to enter an alertable wait state using MsgWaitForMultipleObjects()
/ MsgWaitForMultipleObjectsEx()
?
Upvotes: 0
Views: 1547
Reputation: 4356
it is possible to enter into an alertable wait if you specify MWMO_ALERTABLE flag as the last parameter (dwFlags - the wait type)
Upvotes: 2
Reputation: 108995
MsgWaitForMultipleObjectsEx
puts the thread in an alertable wait state.
From MSDN on SleepEx:
A thread goes into an alertable wait state by calling either SleepEx, MsgWaitForMultipleObjectsEx, WaitForSingleObjectEx, or WaitForMultipleObjectsEx, with the function's bAlertable parameter set to TRUE.
Upvotes: 0