Skip to content

Commit

Permalink
Fix semaphore on Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
LunaTheFoxgirl committed Dec 15, 2024
1 parent 7bb92cf commit 65ec003
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/numem/sync/semaphore.d
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public:

while(true) {

if (!sem_timedwait(handle, &timeout)) {
if (!sem_timedwait(&handle, &timeout)) {
this.subCount();
return true;
}
Expand Down Expand Up @@ -207,7 +207,7 @@ public:
if (rc)
throw nogc_new!SyncError("Unable to signal semaphore");
} else version(Posix) {
auto rc = sem_post(handle);
auto rc = sem_post(&handle);
if (rc)
throw nogc_new!SyncError("Unable to signal semaphore");
}
Expand Down

0 comments on commit 65ec003

Please sign in to comment.