rw_trywrlock man page on Tru64

Man page or keyword search:  
man Server   12896 pages
apropos Keyword Search (all sections)
Output format
Tru64 logo
[printable version]



rw_trywrlock(3scl)					    rw_trywrlock(3scl)

NAME
       rw_trywrlock - Tries to lock a readers/writer lock for write access.

LIBRARY
       SCL Threads Library (libthread.so)

SYNOPSIS
       #include <synch.h>

       int rw_trywrlock(
			 rwlock_t *rwlockp );

PARAMETERS
       Address of the readers/writer lock to try to write-locked.

DESCRIPTION
       This  routine  tries to lock a readers/writer lock for write access. If
       the readers/writer lock is already locked (either  for  read  or	 write
       access,	by another thread), this routine returns EBUSY. Otherwise if 0
       is returned, the readers/writer lock is acquired for write access.

SCL IMPLEMENTATION NOTES
       rw_trywrlock(3scl) is implemented by calling tis_write_trylock(3).

       rw_trywrlock(3scl) first checks if the readers/writer lock is  valid  :
       if  it  is  not, then the readers/writer lock is initialized for intra-
       process thread synchronization (type USYNC_THREAD).

RETURN VALUES
       If an error condition occurs, this routine  returns  an	integer	 value
       indicating the type of error.

       Additional  error  return  information  may be written to the SCL error
       log.  Refer to scl_error_log(4scl) for details.

       Possible return values are  as  follows:	 Successful  completion.   The
       readers/writer  lock is already locked (by another thread).  Error from
       tis_rwlock_init(3) or tis_write_trylock(3). A message is written to the
       SCL errorlog which outlines the error-code mapping. Or:

       An  internal  implementation  error occurred. Refer to the SCL errorlog
       for additional information.

       Note: EFAULT is not returned if rwlockp is an illegal address. An ille‐
       gal address generates a SIGSEGV signal, which by default will abort the
       process and generate a core dump.

ERRORS
       None.

RELATED INFORMATION
       Functions:   rw_rdlock(3scl),   rw_tryrdlock(3scl),    rw_unlock(3scl),
       rw_wrlock(3scl)	       rwlock_destroy(3scl),	    rwlock_init(3scl),
       scl_intro(3scl),	     scl_thread_intro(3scl),	   tis_rwlock_init(3),
       tis_write_trylock(3)

       Files: scl_error_log(4scl)

       Manuals: Solaris Compatibility Libraries User's Guide

							    rw_trywrlock(3scl)
[top]
                             _         _         _ 
                            | |       | |       | |     
                            | |       | |       | |     
                         __ | | __ __ | | __ __ | | __  
                         \ \| |/ / \ \| |/ / \ \| |/ /  
                          \ \ / /   \ \ / /   \ \ / /   
                           \   /     \   /     \   /    
                            \_/       \_/       \_/ 
More information is available in HTML format for server Tru64

List of man pages available for Tru64

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net