I am suspending a thread using an event. When the eventSuspend is signaled the thread waits on it.
// inside the thread function
WaitForSingleObject(eventSuspend, INFINITE );
Now from outside I set it to wait by eventSuspend.ResetEvent()
but loop inside the thread function is kind of long (time consuming). How can I know that the thread has finished whatever it was doing and now it is indeed waiting on this signal?