BOOL ReleaseSemaphore(
HANDLE hSemaphore,
LONG lReleaseCount,
LPLONG lpPreviousCount
);
Parameters
hSemaphore
[in] Handle to the semaphore object. The CreateSemaphore function returns this han……
[/Quote]
看看 lpPreviousCount就知道了
BOOL ReleaseSemaphore(
HANDLE hSemaphore,
LONG lReleaseCount,
LPLONG lpPreviousCount
);
Parameters
hSemaphore
[in] Handle to the semaphore object. The CreateSemaphore function returns this handle.
lReleaseCount
[in] Specifies the amount by which the current count of the semaphore object is to be increased. The value must be greater than zero. If the specified amount would cause the count of the semaphore to exceed the maximum count that was specified when the semaphore was created, the count is not changed and the function returns FALSE.
lpPreviousCount
[out] Long pointer to a 32-bit variable to receive the previous count for the semaphore. This parameter can be NULL if the previous count is not required.