#ifndef _NTEXAPI_H
#if (PHNT_MODE != PHNT_MODE_KERNEL)
NTSYSCALLAPI
NTSTATUS
NTAPI
NtReleaseSemaphore(
_In_ HANDLE SemaphoreHandle,
_In_ LONG ReleaseCount,
_Out_opt_ PLONG PreviousCount
);
View code on GitHub
#ifndef _NTZWAPI_H
NTSYSCALLAPI
NTSTATUS
NTAPI
ZwReleaseSemaphore(
_In_ HANDLE SemaphoreHandle,
_In_ LONG ReleaseCount,
_Out_opt_ PLONG PreviousCount
);
View code on GitHub
Function NtReleaseSemaphore
increments semaphore's counter, opposite to any waiting function (semaphore is signaled when semaphore's counter is greater then zero).
HANDLE
to Semaphore Object opened with SEMAPHORE_MODIFY_STATE
access.
Number of increments, typically set to 1.
Optional pointer to ULONG
value receiving semaphore's counter state before call.