author | Darkvater |
Mon, 30 May 2005 13:35:39 +0000 | |
changeset 1876 | 95c95857ec7b |
parent 1875 | 3a1dba8ed6ea |
child 1877 | e7318705dd04 |
station_cmd.c | file | annotate | diff | comparison | revisions |
--- a/station_cmd.c Mon May 30 13:06:15 2005 +0000 +++ b/station_cmd.c Mon May 30 13:35:39 2005 +0000 @@ -1672,7 +1672,7 @@ SET_EXPENSES_TYPE(EXPENSES_CONSTRUCTION); /* Check if a valid, buildable airport was chosen for construction */ - if (!HASBIT(GetValidAirports(), p1)) return CMD_ERROR; + if (p1 > lengthof(_airport_map5_tiles) || !HASBIT(GetValidAirports(), p1)) return CMD_ERROR; tile = TILE_FROM_XY(x,y);