mirror of
https://github.com/InoriRus/Kyty.git
synced 2026-08-28 05:06:40 +00:00
release 0.1.0
This commit is contained in:
@@ -650,6 +650,8 @@ int KYTY_SYSV_ABI PthreadMutexattrDestroy(PthreadMutexattr* attr)
|
||||
{
|
||||
// PRINT_NAME();
|
||||
|
||||
EXIT_NOT_IMPLEMENTED(attr == nullptr || *attr == nullptr);
|
||||
|
||||
int result = pthread_mutexattr_destroy(&(*attr)->p);
|
||||
|
||||
delete *attr;
|
||||
@@ -757,13 +759,11 @@ int KYTY_SYSV_ABI PthreadMutexDestroy(PthreadMutex* mutex)
|
||||
{
|
||||
PRINT_NAME();
|
||||
|
||||
if (mutex == nullptr)
|
||||
if (mutex == nullptr || *mutex == nullptr)
|
||||
{
|
||||
return KERNEL_ERROR_EINVAL;
|
||||
}
|
||||
|
||||
EXIT_NOT_IMPLEMENTED(*mutex == nullptr);
|
||||
|
||||
int result = pthread_mutex_destroy(&(*mutex)->p);
|
||||
|
||||
printf("\tmutex destroy: %s, %d\n", (*mutex)->name.C_Str(), result);
|
||||
@@ -907,6 +907,8 @@ int KYTY_SYSV_ABI PthreadAttrDestroy(PthreadAttr* attr)
|
||||
{
|
||||
PRINT_NAME();
|
||||
|
||||
EXIT_NOT_IMPLEMENTED(attr == nullptr || *attr == nullptr);
|
||||
|
||||
int result = pthread_attr_destroy(&(*attr)->p);
|
||||
|
||||
delete *attr;
|
||||
@@ -1584,6 +1586,8 @@ int KYTY_SYSV_ABI PthreadRwlockattrDestroy(PthreadRwlockattr* attr)
|
||||
return KERNEL_ERROR_EINVAL;
|
||||
}
|
||||
|
||||
EXIT_NOT_IMPLEMENTED(*attr == nullptr);
|
||||
|
||||
int result = pthread_rwlockattr_destroy(&(*attr)->p);
|
||||
|
||||
delete *attr;
|
||||
@@ -1651,6 +1655,8 @@ int KYTY_SYSV_ABI PthreadCondattrDestroy(PthreadCondattr* attr)
|
||||
return KERNEL_ERROR_EINVAL;
|
||||
}
|
||||
|
||||
EXIT_NOT_IMPLEMENTED(*attr == nullptr);
|
||||
|
||||
int result = pthread_condattr_destroy(&(*attr)->p);
|
||||
|
||||
delete *attr;
|
||||
@@ -2629,6 +2635,13 @@ int KYTY_SYSV_ABI pthread_setspecific(LibKernel::PthreadKey key, void* value)
|
||||
return POSIX_PTHREAD_CALL(LibKernel::PthreadSetspecific(key, value));
|
||||
}
|
||||
|
||||
void* KYTY_SYSV_ABI pthread_getspecific(LibKernel::PthreadKey key)
|
||||
{
|
||||
PRINT_NAME();
|
||||
|
||||
return (LibKernel::PthreadGetspecific(key));
|
||||
}
|
||||
|
||||
int KYTY_SYSV_ABI pthread_mutex_destroy(LibKernel::PthreadMutex* mutex)
|
||||
{
|
||||
PRINT_NAME();
|
||||
|
||||
Reference in New Issue
Block a user