summaryrefslogtreecommitdiff
path: root/src/openttd.cpp
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2010-06-05 13:32:42 +0000
committerfrosch <frosch@openttd.org>2010-06-05 13:32:42 +0000
commit9e53f1e004bf8e65f268b8854a6eb08229e3f2ed (patch)
treefa373b8ec4b6089ac9c1e51f168d44434df8c238 /src/openttd.cpp
parente852bf154f2af40b3cee1f67bef41a78c2056de5 (diff)
downloadopenttd-9e53f1e004bf8e65f268b8854a6eb08229e3f2ed.tar.xz
(svn r19933) -Fix [FS#3804]: Keep _current_company and _local_company in sync during GUI operation.
Diffstat (limited to 'src/openttd.cpp')
-rw-r--r--src/openttd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp
index 0fca283a5..6e8e44973 100644
--- a/src/openttd.cpp
+++ b/src/openttd.cpp
@@ -809,7 +809,6 @@ static void MakeNewGameDone()
IConsoleCmdExec("exec scripts/game_start.scr 0");
SetLocalCompany(COMPANY_FIRST);
- _current_company = _local_company;
InitializeRailGUI();
@@ -895,7 +894,6 @@ static void StartScenario()
StartupDisasters();
SetLocalCompany(COMPANY_FIRST);
- _current_company = _local_company;
Company *c = Company::Get(COMPANY_FIRST);
c->settings = _settings_client.company;
@@ -1231,6 +1229,8 @@ void StateGameLoop()
NewsLoop();
cur_company.Restore();
}
+
+ assert(_current_company == _local_company);
}
/** Create an autosave. The default name is "autosave#.sav". However with