pthread_rwlock_setname_np()

assign name to read-write lock 

Function


SYNOPSIS

#include <pthread.h>

int pthread_setname_np(pthread_rwlock_t *rwlock, const char *name);


DESCRIPTION

The pthread_rwlock_setname_np() function assigns the specified name to the specified rwlock. This is useful for debugging purposes, so that read-write locks can be identified symbolically. If a name is specified for a rwlock, it is displayed by the NuTCRACKER Platform debugging utilities. The name can be obtained programmatically with the pthread_rwlock_getname_np() function.


PARAMETERS

rwlock 

Points to the read-write lock to which the name is assigned.

name 

Points to the name to assign to the read-write lock.


RETURN VALUES

On success, pthread_rwlock_setname_np() returns 0. On error, one of the following values is returned:

ESRCH 

rwlock does not specify a valid read-write lock.

EFAULT 

name is an invalid pointer.


CONFORMANCE

PTC MKS Toolkit UNIX APIs extension.


MULTITHREAD SAFETY LEVEL

MT-safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
pthread_rwlock_getname_np(), pthread_rwlock_init()


PTC MKS Toolkit 10.4 Documentation Build 39.