]> git.sesse.net Git - stockfish/blobdiff - src/evaluate.cpp
Fix a crash issue when traversing PVs.
[stockfish] / src / evaluate.cpp
index b58d4a03dca3b7d291a6a84fbc49ccbd7174e198..333d04aca277d0b456800017980887967d14e09d 100644 (file)
@@ -560,8 +560,7 @@ namespace {
 
     // Bonus for restricting their piece moves
     restricted =   attackedBy[Them][ALL_PIECES]
-                & ~attackedBy[Them][PAWN]
-                & ~attackedBy2[Them]
+                & ~stronglyProtected
                 &  attackedBy[Us][ALL_PIECES];
     score += RestrictedPiece * popcount(restricted);