diff options
author | rubidium <rubidium@openttd.org> | 2011-11-23 20:36:27 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2011-11-23 20:36:27 +0000 |
commit | 560bae8c915f78aeaeed4d3e941827a841b6bf53 (patch) | |
tree | b73555497a8cf8a4068cc01434553313cd964462 /src | |
parent | ecbe29ecb7940a50c631acbae58934537b302e48 (diff) | |
download | openttd-560bae8c915f78aeaeed4d3e941827a841b6bf53.tar.xz |
(svn r23312) -Fix [FS#4849]: assertion could be triggered in case a station was removed just after a vehicle delivered cargo to it
Diffstat (limited to 'src')
-rw-r--r-- | src/station_cmd.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp index 177d2c786..b772da079 100644 --- a/src/station_cmd.cpp +++ b/src/station_cmd.cpp @@ -3027,8 +3027,8 @@ void TriggerWatchedCargoCallbacks(Station *st) */ static bool StationHandleBigTick(BaseStation *st) { - if (!st->IsInUse() && ++st->delete_ctr >= 8) { - delete st; + if (!st->IsInUse()) { + if (++st->delete_ctr >= 8) delete st; return false; } |