Win32: Use CreateSemaphore() instead of CreateSemaphoreW()

This should improve compiler compatibility for those that do not
define `CreateSemaphoreW()`, such as NXDK.
This commit is contained in:
David Reid
2025-08-07 13:23:35 +10:00
parent 02ae7e41f0
commit c87f207f4e
+1 -1
View File
@@ -17852,7 +17852,7 @@ static ma_result ma_event_signal__win32(ma_event* pEvent)
static ma_result ma_semaphore_init__win32(int initialValue, ma_semaphore* pSemaphore) static ma_result ma_semaphore_init__win32(int initialValue, ma_semaphore* pSemaphore)
{ {
*pSemaphore = CreateSemaphoreW(NULL, (LONG)initialValue, LONG_MAX, NULL); *pSemaphore = CreateSemaphore(NULL, (LONG)initialValue, LONG_MAX, NULL);
if (*pSemaphore == NULL) { if (*pSemaphore == NULL) {
return ma_result_from_GetLastError(GetLastError()); return ma_result_from_GetLastError(GetLastError());
} }