]> git.sesse.net Git - stockfish/blobdiff - src/search.cpp
Remove a bogus assert
[stockfish] / src / search.cpp
index f7a39943740d2021854de3a1788e86b70dcce058..dd9e45b92e33b3ad606b6c10a40294fa77349058 100644 (file)
@@ -373,7 +373,7 @@ bool think(const Position& pos, bool infinite, bool ponder, int side_to_move,
   {
       Move bookMove;
       if (get_option_value_string("Book File") != OpeningBook.file_name())
-          OpeningBook.open("book.bin");
+          OpeningBook.open(get_option_value_string("Book File"));
 
       bookMove = OpeningBook.get_move(pos);
       if (bookMove != MOVE_NONE)
@@ -1142,9 +1142,6 @@ namespace {
         search_pv(pos, ss, alpha, beta, depth-2*OnePly, ply, threadID);
         ttMove = ss[ply].pv[ply];
         tte = TT.retrieve(pos.get_key());
-
-        // If tte->move() != MOVE_NONE then it equals ttMove
-        assert(!(tte && tte->move()) || tte->move() == ttMove);
     }
 
     // Initialize a MovePicker object for the current position, and prepare
@@ -1435,7 +1432,7 @@ namespace {
 
     // Go with internal iterative deepening if we don't have a TT move
     if (UseIIDAtNonPVNodes && ttMove == MOVE_NONE && depth >= 8*OnePly &&
-        evaluate(pos, ei, threadID) >= beta - IIDMargin)
+        !isCheck && evaluate(pos, ei, threadID) >= beta - IIDMargin)
     {
         search(pos, ss, beta, Min(depth/2, depth-2*OnePly), ply, false, threadID);
         ttMove = ss[ply].pv[ply];