summaryrefslogtreecommitdiff
path: root/semaphore.h
diff options
context:
space:
mode:
authorrpj <rpj>2001-07-01 14:35:49 +0000
committerrpj <rpj>2001-07-01 14:35:49 +0000
commitc156eacc8b9c6f33f89c7563f2821320be79c2e1 (patch)
treee43c9e4dcfc56577e2dac01c39d4a10ea91c5dc4 /semaphore.h
parent19299847fdd32094b28377db1aea61b0f605dc8b (diff)
2001-07-01 Ross Johnson <rpj@setup1.ise.canberra.edu.au>
Contributed by - Alexander Terekhov. * condvar.c: Fixed lost signal bug reported by Timur Aydin (taydin@snet.net). [RPJ (me) didn't translate the original algorithm correctly.] * semaphore.c: Added sem_post_multiple; this is a useful routine, but it doesn't appear to be standard. For now it's not an exported function.
Diffstat (limited to 'semaphore.h')
-rw-r--r--semaphore.h30
1 files changed, 12 insertions, 18 deletions
diff --git a/semaphore.h b/semaphore.h
index 71679dd..8bb9b64 100644
--- a/semaphore.h
+++ b/semaphore.h
@@ -69,36 +69,30 @@ typedef struct sem_t_ * sem_t;
int sem_init (sem_t * sem,
int pshared,
- unsigned int value
- );
+ unsigned int value);
-int sem_destroy (sem_t * sem
- );
+int sem_destroy (sem_t * sem);
-int sem_trywait (sem_t * sem
- );
+int sem_trywait (sem_t * sem);
-int sem_wait (sem_t * sem
- );
+int sem_wait (sem_t * sem);
-int sem_post (sem_t * sem
- );
+int sem_post (sem_t * sem);
+
+int sem_post_multiple (sem_t * sem,
+ int count);
int sem_open (const char * name,
int oflag,
mode_t mode,
- unsigned int value
- );
+ unsigned int value);
-int sem_close (sem_t * sem
- );
+int sem_close (sem_t * sem);
-int sem_unlink (const char * name
- );
+int sem_unlink (const char * name);
int sem_getvalue (sem_t * sem,
- int * sval
- );
+ int * sval);
#ifdef __cplusplus
} /* End of extern "C" */