(svn r21440) -Codechange: pass a pointer to just past the end of the argv array around in FormatString and friends

This commit is contained in:
yexo
2010-12-09 00:15:38 +00:00
parent ca0cf460f3
commit 6c32eef05d
3 changed files with 64 additions and 63 deletions

View File

@@ -49,8 +49,8 @@ TownNameParams::TownNameParams(const Town *t) :
char *GetTownName(char *buff, const TownNameParams *par, uint32 townnameparts, const char *last)
{
if (par->grfid == 0) {
int64 temp[1] = { townnameparts };
return GetStringWithArgs(buff, par->type, temp, last);
int64 args[1] = { townnameparts };
return GetStringWithArgs(buff, par->type, args, endof(args), last);
}
return GRFTownNameGenerate(buff, par->grfid, par->type, townnameparts, last);