Fix two bugs in reading position diagram
[xboard.git] / moves.c
diff --git a/moves.c b/moves.c
index 6310201..fd05e38 100644 (file)
--- a/moves.c
+++ b/moves.c
@@ -126,6 +126,7 @@ ChessSquare CharToPiece(c)
      int c;
 {
      int i;
+     if(c == '.') return EmptySquare;
      for(i=0; i< (int) EmptySquare; i++)
           if(pieceNickName[i] == c) return (ChessSquare) i;
      for(i=0; i< (int) EmptySquare; i++)