pull request #798 - fix typo in disclosure \
of vanquired monsters. Pull request from janne-hmp: the test for how many spaces to insert in front of "the <unique monster>" couldn't match prefix "the " because it was specifying a length of 3 instead of the 4 required to include the trailing space. Despite that clear error, the code worked as intended because the default value of 0 is the same as an explicit value of 0 it would have gotten if it had matched "the ". So there is no change in the resulting vanquished monsters display. Closes #798
This commit is contained in:
@@ -2744,7 +2744,7 @@ list_vanquished(char defquery, boolean ask)
|
||||
makeplural(mons[i].pmnames[NEUTRAL]));
|
||||
}
|
||||
/* number of leading spaces to match 3 digit prefix */
|
||||
pfx = !strncmpi(buf, "the ", 3) ? 0
|
||||
pfx = !strncmpi(buf, "the ", 4) ? 0
|
||||
: !strncmpi(buf, "an ", 3) ? 1
|
||||
: !strncmpi(buf, "a ", 2) ? 2
|
||||
: !digit(buf[2]) ? 4 : 0;
|
||||
|
||||
Reference in New Issue
Block a user