1.1 --- a/src/chess/bishop.c Mon Mar 31 11:41:08 2014 +0200 1.2 +++ b/src/chess/bishop.c Mon Mar 31 14:00:58 2014 +0200 1.3 @@ -42,13 +42,13 @@ 1.4 uint8_t y = move->fromrow; 1.5 uint8_t x = move->fromfile; 1.6 1.7 - do { 1.8 + while (x != move->tofile-dx && y != move->torow-dy) { 1.9 x += dx; 1.10 y += dy; 1.11 if (board[y][x]) { 1.12 return 1; 1.13 } 1.14 - } while (x != move->tofile && y != move->torow); 1.15 + } 1.16 1.17 return 0; 1.18 }