DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Threads

Recursive mutual exclusion

The regular mutex lock (shown earlier) will deadlock the calling thread on attempts to re-lock a lock that it already holds. A recursive mutually exclusive lock (recursive mutex or rmutex) allows the holder of a lock to re-lock without deadlock; other threads will block normally.

   int rmutex_lock(  rmutex_t *rmutex);
   int rmutex_unlock(rmutex_t *rmutex);
Considerations for the use of recursive mutex locks:
Next topic: Reader-writer locks
Previous topic: Spin locks

© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 27 April 2004