Skip to content

Commit 65ec003

Browse files
Fix semaphore on Linux
1 parent 7bb92cf commit 65ec003

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

source/numem/sync/semaphore.d

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ public:
141141

142142
while(true) {
143143

144-
if (!sem_timedwait(handle, &timeout)) {
144+
if (!sem_timedwait(&handle, &timeout)) {
145145
this.subCount();
146146
return true;
147147
}
@@ -207,7 +207,7 @@ public:
207207
if (rc)
208208
throw nogc_new!SyncError("Unable to signal semaphore");
209209
} else version(Posix) {
210-
auto rc = sem_post(handle);
210+
auto rc = sem_post(&handle);
211211
if (rc)
212212
throw nogc_new!SyncError("Unable to signal semaphore");
213213
}

0 commit comments

Comments
 (0)