Minimal changes to get it to compile (a few taken from David Given ack-6.0pre5)
[Ack-5.5.git] / lang / cem / cemcom.ansi / cstoper.c
index 6ec57f4..f0ef320 100644 (file)
@@ -16,7 +16,7 @@
 #include       "Lpars.h"
 #include       "assert.h"
 
-arith full_mask[MAXSIZE];/* full_mask[1] == 0XFF, full_mask[2] == 0XFFFF, .. */
+arith full_mask[MAXSIZE + 1];/* full_mask[1] == 0XFF, full_mask[2] == 0XFFFF, .. */
 #ifndef NOCROSS
 arith max_int;         /* maximum integer on target machine    */
 arith max_unsigned;    /* maximum unsigned on target machine   */
@@ -247,7 +247,7 @@ init_cst()
 
        while (!(bt < 0))       {
                bt = (bt << 8) + 0377, i++;
-               if (i == MAXSIZE)
+               if (i == MAXSIZE + 1)
                        fatal("array full_mask too small for this machine");
                full_mask[i] = bt;
        }