mirror of
https://github.com/fluencelabs/musl
synced 2025-06-25 12:42:02 +00:00
fix signed left-shift overflow in pthread_condattr_setpshared
This commit is contained in:
@ -4,6 +4,6 @@ int pthread_condattr_setpshared(pthread_condattr_t *a, int pshared)
|
||||
{
|
||||
if (pshared > 1U) return EINVAL;
|
||||
a->__attr &= 0x7fffffff;
|
||||
a->__attr |= pshared<<31;
|
||||
a->__attr |= (unsigned)pshared<<31;
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user