]> git.sesse.net Git - stockfish/commitdiff
Fix some races
authorJoona Kiiski <joona.kiiski@gmail.com>
Mon, 22 Feb 2010 13:15:55 +0000 (15:15 +0200)
committerMarco Costalba <mcostalba@gmail.com>
Tue, 23 Feb 2010 06:22:56 +0000 (07:22 +0100)
Resurrect extra check for sleeping in POSIX code.
This necessary to prevent ugly races between
thread_broadcast and thread_cond_wait.

After thread has woken up, it marks itself as available.
Another thread must not do this, because of possible race.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>

No differences found