From 0577d7cbf87af41cc9553281efedfbdd85cfb11e Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Sat, 3 Oct 2015 14:28:47 +0100 Subject: [PATCH] progsig: Fix test remove rail action clearing signal programs. This could be triggered by using shift, using the land info window, etc. --- src/rail_cmd.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rail_cmd.cpp b/src/rail_cmd.cpp index e363823621..ec8f5a6b98 100644 --- a/src/rail_cmd.cpp +++ b/src/rail_cmd.cpp @@ -645,7 +645,7 @@ CommandCost CmdRemoveSingleRail(TileIndex tile, DoCommandFlag flags, uint32 p1, /* Charge extra to remove signals on the track, if they are there */ if (HasSignalOnTrack(tile, track)) { - CheckRemoveSignal(tile, track); + if (flags & DC_EXEC) CheckRemoveSignal(tile, track); cost.AddCost(DoCommand(tile, track, 0, flags, CMD_REMOVE_SIGNALS)); }