diff options
-rw-r--r-- | sem_post.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -85,7 +85,7 @@ sem_post (sem_t * sem) #else /* NEED_SEM */ - else if (InterlockedExchangeAdd((LPLONG) &(*sem)->value, (LONG) 1) < 0 + else if (InterlockedIncrement((LPLONG) &(*sem)->value) <= 0 && !ReleaseSemaphore((*sem)->sem, 1, NULL)) #endif /* NEED_SEM */ |