X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fsearch.cpp;h=652893282ca35bc51767bcee3d535aa2328ff10f;hb=252537fd9c8cb60f765ea390d2464a42adeafc0a;hp=fff00026c6cdad7380c32d1e4b53471f65efae05;hpb=2170fa18bf59f977138f9de2389cbfdd85d84415;p=stockfish diff --git a/src/search.cpp b/src/search.cpp index fff00026..65289328 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -1168,7 +1168,7 @@ namespace { // Expensive mate threat detection (only for PV nodes) if (PvNode) - mateThreat = pos.has_mate_threat(opposite_color(pos.side_to_move())); + mateThreat = pos.has_mate_threat(); // Initialize a MovePicker object for the current position MovePicker mp = MovePicker(pos, ttMove, depth, H, ss, (PvNode ? -VALUE_INFINITE : beta)); @@ -2035,7 +2035,7 @@ namespace { if ( m != MOVE_NULL && before != VALUE_NONE && after != VALUE_NONE - && pos.captured_piece() == NO_PIECE_TYPE + && pos.captured_piece_type() == PIECE_TYPE_NONE && !move_is_special(m)) H.set_gain(pos.piece_on(move_to(m)), move_to(m), -(before + after)); }