Syncobjs Event and BlockWrite() question

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Syncobjs Event and BlockWrite() question

Brian
When using WaitFor() , ResetEvent and SetEvent as a semaphore , if a thread is using BlockWrite() and the execution of BlockWrite() is conditional on  WaitFor() , will BlockWrite() continue to function after it is called once MySemaphore.ResetEvent is called ?

A pseudo code  example below

---------main loop----------
MySemaphore.ResetEvent;

 doing something

MySemaphore.SetEvent
 
 ----- Thread------------
  MySemaphore.WaitFor(10);

  BlockWrite()

-------------------------

Thanks
Brian
Loading...