[Previous] [Contents] [Next]

_sleepon_lock()

@@@Lock a sleepon

Synopsis:

#include <@@@unistd.h>

int _sleepon_lock( sleepon_t * l );

Library:

libc

Description:

The _sleepon_lock() function locks the mutex asociated with the sleepon structure, l.

It must be called before the _sleepon_wait(), _sleepon_sleepon(), and _sleepon_broadcast() functions.

Returns:

The same values as pthread_mutex_lock():

EOK
Success.
EAGAIN
Insufficient system resources available to lock the mutex.
EDEADLK
Calling thread already owns mutex and the mutex doesn't allow recursive behavior.
EINVAL
Invalid mutex mutex.

Classification:

@@@NONE

Safety:
Cancellation point No
Interrupt handler No
Signal handler No
Thread No

See also:


[Previous] [Contents] [Next]