]> thyrsus.com Git - bluemoon.git/commitdiff
Bug fix.
authorEric S. Raymond <esr@thyrsus.com>
Mon, 21 Dec 1998 03:11:25 +0000 (03:11 +0000)
committerEric S. Raymond <esr@thyrsus.com>
Mon, 21 Dec 1998 03:11:25 +0000 (03:11 +0000)
bluemoon.c

index 12a5e4204535c658a26a2c808fb0afdfe17c58aa..355a06ba57aa6627d150c448e6661d6aecc0244f 100644 (file)
@@ -47,8 +47,8 @@
 #define CLUBS          3
 #define NSUITS         4
 
-#define GRID_WIDTH     14      /*    13+1  */
-#define GRID_LENGTH    56      /* 4*(13+1) */
+#define GRID_WIDTH     (SUIT_LENGTH + 1)
+#define GRID_LENGTH    (NSUITS * GRID_WIDTH)
 #define PACK_SIZE      52
 
 #define BASEROW                1
@@ -234,7 +234,7 @@ static void play_game()
 {
     int dead=0, i, j;
     char c;
-    int select[4], card;
+    int select[NSUITS], card;
 
     nmove = 0;
     memset(journal, '\0', sizeof(journal));
@@ -258,7 +258,7 @@ static void play_game()
 
        if (dead < 4)
        {
-           char        live[NSUITS], *lp = live;
+           char        live[NSUITS+1], *lp = live;
 
            for (i=0;i<4;i++)
            {