The board markers would stay on when the board was cleared, and a
no-longer-present piece would stay selected, leading to deletion of the
first piece that you tried to select.
switch (selection) {
case ClearBoard:
+ fromX = fromY = killX = killY = -1; // [HGM] abort any move entry in progress
+ MarkTargetSquares(1);
CopyBoard(currentBoard, boards[0]);
CopyBoard(menuBoard, initialPosition);
if (gameMode == IcsExamining && ics_type == ICS_FICS) {