The moves parsed from a variation were stored in the moveList without
appended linefeed. This caused errors if the variation extended to
beyond the end of the main line,into a hitherto unused part of the move
list, as the linefeed was then not there from the overwritten move. As a
result moves sent to the engine were concatenated, triggering
illegal-move messages and bringing the engine out of phase.
moveList[endPV-1][1] = fromY + ONE;
moveList[endPV-1][2] = toX + AAA;
moveList[endPV-1][3] = toY + ONE;
+ moveList[endPV-1][4] = promoChar;
+ moveList[endPV-1][5] = NULLCHAR;
+ strncat(moveList[endPV-1], "\n", MOVE_LEN);
if(storeComments)
CoordsToAlgebraic(boards[endPV - 1],
PosFlags(endPV - 1),