Explicitly set the altlabels array size
This will allow the compiler to complain after you add new glyphs.
This commit is contained in:
+1
-1
@@ -131,7 +131,7 @@ const struct symdef def_warnsyms[WARNCOUNT] = {
|
|||||||
*
|
*
|
||||||
* If adding to or removing from this list, please note that,
|
* If adding to or removing from this list, please note that,
|
||||||
* for builds with tile support, there is an array called altlabels[] in
|
* for builds with tile support, there is an array called altlabels[] in
|
||||||
* win/share/tiletext.c that requires the same number of elements as
|
* win/share/tilemap.c that requires the same number of elements as
|
||||||
* this, in the same order. It is used for tile name matching when
|
* this, in the same order. It is used for tile name matching when
|
||||||
* parsing other.txt because some of the useful tile names don't exist
|
* parsing other.txt because some of the useful tile names don't exist
|
||||||
* within NetHack itself.
|
* within NetHack itself.
|
||||||
|
|||||||
+1
-1
@@ -704,7 +704,7 @@ struct {
|
|||||||
int idx;
|
int idx;
|
||||||
const char *betterlabel;
|
const char *betterlabel;
|
||||||
const char *expectedlabel;
|
const char *expectedlabel;
|
||||||
} altlabels[] = {
|
} altlabels[MAXPCHARS] = {
|
||||||
{S_stone, "dark part of a room", "dark part of a room"},
|
{S_stone, "dark part of a room", "dark part of a room"},
|
||||||
{S_vwall, "vertical wall", "wall"},
|
{S_vwall, "vertical wall", "wall"},
|
||||||
{S_hwall, "horizontal wall", "wall"},
|
{S_hwall, "horizontal wall", "wall"},
|
||||||
|
|||||||
Reference in New Issue
Block a user