mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-06 02:55:49 +03:00
LibPthread: Implement pthread_mutexattr_init() and _destroy()
This commit is contained in:
parent
eaab7f5672
commit
9ddfe694f2
Notes:
sideshowbarker
2024-07-19 10:56:31 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/9ddfe694f2c
@ -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;
|
||||
|
@ -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 {};
|
||||
|
Loading…
Reference in New Issue
Block a user