mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2025-02-21 00:27:19 +08:00
[components/libc/posix]fix the errors that assigning an integer to a pointer and always return EINVAL.
This commit is contained in:
parent
79324c0b4c
commit
0bac8c4f90
@ -45,7 +45,10 @@ int pthread_barrierattr_setpshared(pthread_barrierattr_t *attr, int pshared)
|
||||
if (!attr)
|
||||
return EINVAL;
|
||||
if (pshared == PTHREAD_PROCESS_PRIVATE)
|
||||
attr = PTHREAD_PROCESS_PRIVATE;
|
||||
{
|
||||
*attr = PTHREAD_PROCESS_PRIVATE;
|
||||
return 0;
|
||||
}
|
||||
|
||||
return EINVAL;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user