mirror of https://gitee.com/openkylin/glibc.git
git-barrier-1
commit 29bc8736d1fdb80d2416b3920080dad58b32bf44 Author: Samuel Thibault <samuel.thibault@ens-lyon.org> Date: Sun Feb 9 23:02:13 2020 +0000 htl: Fix barrier_wait with one thread Gbp-Pq: Topic hurd-i386 Gbp-Pq: Name git-barrier-1.diff
This commit is contained in:
parent
0a9c050a7b
commit
b3ef4677bc
|
@ -29,7 +29,9 @@ pthread_barrier_wait (pthread_barrier_t *barrier)
|
|||
{
|
||||
barrier->__pending = barrier->__count;
|
||||
|
||||
if (barrier->__count > 1)
|
||||
if (barrier->__count == 1)
|
||||
__pthread_spin_unlock (&barrier->__lock);
|
||||
else
|
||||
{
|
||||
struct __pthread *wakeup;
|
||||
unsigned n = 0;
|
||||
|
|
Loading…
Reference in New Issue