mirror of https://github.com/OpenTTD/OpenTTD
(svn r17470) -Fix (r17460): possible crash when overbuiling rail by station
parent
f40885ec50
commit
8cbcf17421
|
@ -727,7 +727,7 @@ CommandCost CheckFlatLandBelow(TileIndex tile, uint w, uint h, DoCommandFlag fla
|
||||||
* build isn't a rail station it's INVALID_RAILTYPE. */
|
* build isn't a rail station it's INVALID_RAILTYPE. */
|
||||||
if (rt != INVALID_RAILTYPE &&
|
if (rt != INVALID_RAILTYPE &&
|
||||||
IsPlainRailTile(tile_cur) && !HasSignals(tile_cur) &&
|
IsPlainRailTile(tile_cur) && !HasSignals(tile_cur) &&
|
||||||
HasPowerOnRail(GetRailType(tile), rt)) {
|
HasPowerOnRail(GetRailType(tile_cur), rt)) {
|
||||||
/* Allow overbuilding if the tile:
|
/* Allow overbuilding if the tile:
|
||||||
* - has rail, but no signals
|
* - has rail, but no signals
|
||||||
* - it has exactly one track
|
* - it has exactly one track
|
||||||
|
|
Loading…
Reference in New Issue