]> git.cworth.org Git - ttt/commitdiff
Fixed board_make_move to use TTT_CELL_EMPTY
authorKevin Worth <kevin@theworths.org>
Tue, 13 Dec 2005 20:40:23 +0000 (20:40 +0000)
committerKevin Worth <kevin@theworths.org>
Tue, 13 Dec 2005 20:40:23 +0000 (20:40 +0000)
src/ttt-board.c

index 92391ebd2d7db4243ed14f76ff7253fa2c9a963f..8c34b3e0074165300f35958e73be7637bde7081f 100644 (file)
@@ -104,7 +104,7 @@ ttt_board_write (ttt_board_t *board, FILE *file)
  
 ttt_error_t ttt_board_make_move (ttt_board_t *board, int move)
 {  
  
 ttt_error_t ttt_board_make_move (ttt_board_t *board, int move)
 {  
-    if (board->cells[move] != '_')
+    if (board->cells[move] != TTT_CELL_EMPTY)
        return TTT_ERROR_NOT_VALID_MOVE;
 
     board->cells[move] = board->current_player;
        return TTT_ERROR_NOT_VALID_MOVE;
 
     board->cells[move] = board->current_player;