diff options
Diffstat (limited to 'lib/libpthread/uthread/uthread_mattr_kind_np.c')
-rw-r--r-- | lib/libpthread/uthread/uthread_mattr_kind_np.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/libpthread/uthread/uthread_mattr_kind_np.c b/lib/libpthread/uthread/uthread_mattr_kind_np.c index 3eeabff038a..c145a1f8992 100644 --- a/lib/libpthread/uthread/uthread_mattr_kind_np.c +++ b/lib/libpthread/uthread/uthread_mattr_kind_np.c @@ -61,4 +61,18 @@ pthread_mutexattr_getkind_np(pthread_mutexattr_t attr) } return(ret); } + +int +pthread_mutexattr_settype(pthread_mutexattr_t *attr, int type) +{ + int ret; + if (attr == NULL || *attr == NULL || type >= MUTEX_TYPE_MAX) { + errno = EINVAL; + ret = -1; + } else { + (*attr)->m_type = type; + ret = 0; + } + return(ret); +} #endif |