diff --git a/Libraries/LibC/sys/types.h b/Libraries/LibC/sys/types.h index 45c376dc010fc28b5e8b185693e3e8a3d272e871..2066f23dfcad62da64edfe5e887df9a2875fd173 100644 --- a/Libraries/LibC/sys/types.h +++ b/Libraries/LibC/sys/types.h @@ -65,7 +65,9 @@ typedef void* pthread_key_t; typedef void* pthread_once_t; typedef uint32_t pthread_mutex_t; typedef void* pthread_attr_t; -typedef void* pthread_mutexattr_t; +typedef struct __pthread_mutexattr_t { + int type; +} pthread_mutexattr_t; typedef struct __pthread_cond_t { void* storage; diff --git a/Libraries/LibPthread/pthread.cpp b/Libraries/LibPthread/pthread.cpp index 6e43fe1281e89c988896683d1b4b76c79899bf9b..d3a54b8e69f07b2467ad503c5637eda67cfb4345 100644 --- a/Libraries/LibPthread/pthread.cpp +++ b/Libraries/LibPthread/pthread.cpp @@ -125,6 +125,17 @@ int pthread_mutex_unlock(pthread_mutex_t* mutex) return 0; } +int pthread_mutexattr_init(pthread_mutexattr_t* attr) +{ + attr->type = PTHREAD_MUTEX_NORMAL; + return 0; +} + +int pthread_mutexattr_destroy(pthread_mutexattr_t*) +{ + return 0; +} + int pthread_attr_init(pthread_attr_t* attributes) { auto* impl = new PthreadAttrImpl {};