From: Eric S. Raymond Date: Wed, 7 Jun 2017 10:24:18 +0000 (-0400) Subject: Magic-number cleanup. X-Git-Tag: 1.1~583 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=c1f1f2f79f96542aecbb24ab1cf1914d0607b4e0;p=open-adventure.git Magic-number cleanup. --- diff --git a/advent.h b/advent.h index 23f3406..192248d 100644 --- a/advent.h +++ b/advent.h @@ -61,9 +61,7 @@ struct game_t { extern struct game_t game; -extern long ATLOC[], FIXED[], - LINK[], LNLENG, LNPOSN, - PARMS[], PLACE[]; +extern long ATLOC[], FIXED[], LINK[], LNLENG, LNPOSN, PARMS[], PLACE[]; extern char rawbuf[LINESIZE], INLINE[LINESIZE+1], MAP1[], MAP2[]; extern FILE *logfp; extern bool oldstyle; diff --git a/init.c b/init.c index 879ea08..e3b84fb 100644 --- a/init.c +++ b/init.c @@ -32,7 +32,7 @@ /* Note: * - the object count limit has been abstracted as NOBJECTS - * - the random message limit has been abstracted as RTXSIZE + * - the random message limit has been abstracted as RTXSIZ * - maximum locations limit has been abstracted as LOCSIZ */ diff --git a/main.c b/main.c index 21a8fa8..988fcc1 100644 --- a/main.c +++ b/main.c @@ -14,7 +14,7 @@ struct game_t game; -long ATLOC[186], FIXED[NOBJECTS+1], +long ATLOC[LOCSIZ+1], FIXED[NOBJECTS+1], LINK[NOBJECTS*2 + 1], LNLENG, LNPOSN, PARMS[26], PLACE[NOBJECTS+1]; char rawbuf[LINESIZE], INLINE[LINESIZE+1], MAP1[129], MAP2[129];