--- a/src/station_cmd.cpp Tue Jun 17 10:32:49 2008 +0000
+++ b/src/station_cmd.cpp Tue Jun 17 13:22:13 2008 +0000
@@ -1102,7 +1102,7 @@
tile_delta = (axis == AXIS_X ? TileDiffXY(1, 0) : TileDiffXY(0, 1));
track = AxisToTrack(axis);
- layout_ptr = (byte*)alloca(numtracks * plat_len);
+ layout_ptr = AllocaM(byte, numtracks * plat_len);
GetStationLayout(layout_ptr, numtracks, plat_len, statspec);
numtracks_orig = numtracks;
@@ -1584,7 +1584,7 @@
CommandCost CmdRemoveRoadStop(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
{
/* Make sure the specified tile is a road stop of the correct type */
- if (!IsTileType(tile, MP_STATION) || !IsRoadStop(tile) || (uint32)GetRoadStopType(tile) != p2) return CMD_ERROR;
+ if (!IsTileType(tile, MP_STATION) || !IsRoadStop(tile) || (uint32)GetRoadStopType(tile) != GB(p2, 0, 1)) return CMD_ERROR;
Station *st = GetStationByTile(tile);
/* Save the stop info before it is removed */
bool is_drive_through = IsDriveThroughStopTile(tile);