pthread_attr_getinheritsched(3T) returns the scheduling policy set by pthread_attr_setinheritsched().
Prototype: int pthread_attr_getinheritsched(pthread_attr_t *tattr, int *inherit);
#include <pthread.h> pthread_attr_t tattr; int inherit; int ret; /* get scheduling policy and priority of the creating thread */ ret = pthread_attr_getinheritsched (&tattr, &inherit);
Returns zero after completing successfully. Any other returned value indicates that an error occurred. If the following condition occurs, the function fails and returns the corresponding value.