(svn r20540) -Fix [FS#4049](r20480): use CmdDeleteTown instead of direct use of operator delete

This commit is contained in:
smatz
2010-08-18 15:22:40 +00:00
parent e68cf6bd81
commit ca2d4c5d6e

View File

@@ -1764,7 +1764,7 @@ static Town *CreateRandomTown(uint attempts, uint32 townnameparts, TownSize size
/* if the population is still 0 at the point, then the
* placement is so bad it couldn't grow at all */
if (t->population > 0) return t;
delete t;
DoCommand(t->xy, t->index, 0, DC_EXEC, CMD_DELETE_TOWN);
} while (--attempts != 0);
return NULL;