ResetEvent
The ResetEvent
function sets the state of the specified event object to nonsignaled.
BOOL ResetEvent(
HANDLE hEvent |
// handle of event
object |
); |
|
Parameters
hEvent
Identifies
the event object. The CreateEventQTG5JZ function returns this handle.
Windows
NT: The handle must have
EVENT_MODIFY_STATE access. For more information, see Interprocess
Synchronization Objects
Return Values
If the
function succeeds, the return value is nonzero.
If the
function fails, the return value is zero. To get extended error information,
call GetLastError
Remarks
The state of
an event object remains nonsignaled until it is explicitly set to signaled by
the SetEvent
The ResetEvent
function is used primarily for manual-reset event objects, which must be set
explicitly to the nonsignaled state. Auto-reset event objects automatically
change from signaled to nonsignaled after a single waiting thread is released.
See Also