summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2009-09-08 07:16:26 +0000
committersmatz <smatz@openttd.org>2009-09-08 07:16:26 +0000
commit8cbcf17421a841696185db6318f2ed44ede9031c (patch)
treeabbbe94d26542fd08e4421f56158a21eb450bbad /src
parentf40885ec506b080fe86e26b86155beb4ce45caaa (diff)
downloadopenttd-8cbcf17421a841696185db6318f2ed44ede9031c.tar.xz
(svn r17470) -Fix (r17460): possible crash when overbuiling rail by station
Diffstat (limited to 'src')
-rw-r--r--src/station_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
index c8ad6c66d..c7a91ef23 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -727,7 +727,7 @@ CommandCost CheckFlatLandBelow(TileIndex tile, uint w, uint h, DoCommandFlag fla
* build isn't a rail station it's INVALID_RAILTYPE. */
if (rt != INVALID_RAILTYPE &&
IsPlainRailTile(tile_cur) && !HasSignals(tile_cur) &&
- HasPowerOnRail(GetRailType(tile), rt)) {
+ HasPowerOnRail(GetRailType(tile_cur), rt)) {
/* Allow overbuilding if the tile:
* - has rail, but no signals
* - it has exactly one track