]> git.ipfire.org Git - thirdparty/glibc.git/commit
nptl: Use a single loop in pthread_cond_wait instaed of a nested loop
authorMalte Skarupke <malteskarupke@fastmail.fm>
Wed, 4 Dec 2024 13:03:44 +0000 (08:03 -0500)
committerCarlos O'Donell <carlos@redhat.com>
Fri, 17 Jan 2025 19:56:58 +0000 (14:56 -0500)
commit929a4764ac90382616b6a21f099192b2475da674
tree886660a2a2c2627681ebfb00826746b927d49d59
parentc36fc50781995e6758cae2b6927839d0157f213c
nptl: Use a single loop in pthread_cond_wait instaed of a nested loop

The loop was a little more complicated than necessary. There was only one
break statement out of the inner loop, and the outer loop was nearly empty.
So just remove the outer loop, moving its code to the one break statement in
the inner loop. This allows us to replace all gotos with break statements.

Signed-off-by: Malte Skarupke <malteskarupke@fastmail.fm>
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
nptl/pthread_cond_wait.c