*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->OpenBSD man pages -> pthread_mutex_trylock (3)              
Title
Content
Arch
Section
 

TEX_TRYLOCK(3)

Contents


PTHREAD_MU

NAME    [Toc]    [Back]

     pthread_mutex_trylock - attempt  to  lock  a  mutex  without
blocking

SYNOPSIS    [Toc]    [Back]

     #include <pthread.h>

     int
     pthread_mutex_trylock(pthread_mutex_t *mutex);

DESCRIPTION    [Toc]    [Back]

     The  pthread_mutex_trylock()  function  locks mutex.  If the
mutex is already
 locked, pthread_mutex_trylock() will not block waiting
for the mutex,
 but will return an error condition.

RETURN VALUES    [Toc]    [Back]

     If  successful,  pthread_mutex_trylock()  will  return zero,
otherwise an error
 number will be returned to indicate the error.

ERRORS    [Toc]    [Back]

     pthread_mutex_trylock() will fail if:

     [EINVAL]      The value specified by mutex is invalid.

     [EBUSY]       mutex is already locked.

SEE ALSO    [Toc]    [Back]

      
      
     pthread_mutex_destroy(3), pthread_mutex_init(3), pthread_mutex_lock(3),
     pthread_mutex_unlock(3)

STANDARDS    [Toc]    [Back]

     pthread_mutex_trylock()   conforms  to  ISO/IEC  9945-1:1996
(``POSIX'').

OpenBSD     3.6                           July      30,      1998
[ Back ]
 Similar pages
Name OS Title
pthread_mutex_lock FreeBSD lock a mutex
pthread_mutex_lock OpenBSD lock a mutex
tis_mutex_trylock Tru64 Attempts to lock the specified mutex
pthread_mutex_trylock Tru64 Attempts to lock the specified mutex, without waiting if already locked
pthread_mutexattr_gettype Tru64 Obtains the mutex type attribute in the specified mutex attributes object
pthread_mutexattr_settype Tru64 Specifies the mutex type attribute that is used when a mutex is created
dns-helper Linux Non-blocking name resolver interface.
mq_setattr HP-UX set the blocking status of a message queue associated with a descriptor
esddsp Linux attempt to reroute audio device to esd
undelete FreeBSD attempt to recover a deleted file
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service