#include <semaphore.h>
|
int
sem_getvalue (sem_t * sem, int * sval); |
sem_t psem; int val; if (sem_init(&psem, 0, 1) < 0) { perror("sem_init"); return -1; } if( sem_getvalue(psem, &val) == -1 ) { perror("sem_getvalue failed"); return -1; }
[EINVAL] | |
The sem argument points to an invalid semaphore. | |
© 2008 Nokia Corporation. All rights reserved. This documentation can be used in the connection with this Product to help and support the user. |