mirror of
git://git.musl-libc.org/musl
synced 2025-03-06 20:48:29 +01:00
fix signed left-shift overflow in pthread_condattr_setpshared
This commit is contained in:
parent
ad85fcb568
commit
380857bf21
1 changed files with 1 additions and 1 deletions
|
@ -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;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue