summaryrefslogtreecommitdiff
path: root/sem_init.c
diff options
context:
space:
mode:
authorrpj <rpj>2004-10-19 13:24:40 +0000
committerrpj <rpj>2004-10-19 13:24:40 +0000
commit8c8bcc5d1737002a9d153105c16b262d2e201efa (patch)
treeba43c6049cc7e361a3eb875015aeb4032c01c559 /sem_init.c
parent45b1b8cb2a6588f9316f780d8cefe11c181a9a17 (diff)
Semaphore speedups - alpha, but passes testsuite
Diffstat (limited to 'sem_init.c')
-rw-r--r--sem_init.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sem_init.c b/sem_init.c
index eca0026..af0e285 100644
--- a/sem_init.c
+++ b/sem_init.c
@@ -127,8 +127,9 @@ sem_init (sem_t * sem, int pshared, unsigned int value)
#else /* NEED_SEM */
+ s->value = value;
s->sem = CreateSemaphore (NULL, /* Always NULL */
- (long) value, /* Initial value */
+ (long) 0, /* Force threads to wait */
(long) _POSIX_SEM_VALUE_MAX, /* Maximum value */
NULL); /* Name */