]> git.sesse.net Git - stockfish/commit
Fixes a Chess960 bug when playing with more than one search thread.
authorTord Romstad <tord@cm-84.215.101.133.getinternet.no>
Sun, 24 Jan 2010 15:09:32 +0000 (16:09 +0100)
committerTord Romstad <tord@cm-84.215.101.133.getinternet.no>
Sun, 24 Jan 2010 15:09:32 +0000 (16:09 +0100)
commit1588a4e84695e48e47c5c8b83d14ead285530c45
treed7a3b671ef3f52a2f6bff45e0db7e203946f6a09
parent3975a2b94f00dc9f3ead1589436256a39120368a
Fixes a Chess960 bug when playing with more than one search thread.

The init_eval() function corrupted the static array castleRightsMask[]
in the Position class, resulting in instant crashes in most Chess960
games. Fixed by repairing the damage directly after the function is
called. Also modified the Position::to_fen() function to display
castle rights correctly for Chess960 positions, and added sanity checks
for uncastled rook files in Position::is_ok().
src/position.cpp
src/search.cpp