Does SetEvent unblock one or all waiting threads?

c, winapi

Solution

It depends on if it is a manual or auto-reset event. If it is a manual reset, then multiple threads can be released until it is reset. If it is auto-reset, then only one will be signaled.

Problem

If 2 or more threads are waiting on an event, does SetEvent unblock one or all of them(Or some of them) ?

Original source