diff options
author | yexo <yexo@openttd.org> | 2011-06-03 19:18:39 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2011-06-03 19:18:39 +0000 |
commit | cf11a1e98e4d5a4bfc6929b78a9fb28108f763a8 (patch) | |
tree | 92917d8ce904d002e0b034df3d0df6db2d27f49b /src/ai/ai_config.cpp | |
parent | b1812c9b02a3975f0d3f9a12e23f961717df22a0 (diff) | |
download | openttd-cf11a1e98e4d5a4bfc6929b78a9fb28108f763a8.tar.xz |
(svn r22534) -Fix [FS#4631] (r21250): doing rescan_ai in a game with running AIs caused a crash
Diffstat (limited to 'src/ai/ai_config.cpp')
-rw-r--r-- | src/ai/ai_config.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ai/ai_config.cpp b/src/ai/ai_config.cpp index 8ec213cd8..a00cf4867 100644 --- a/src/ai/ai_config.cpp +++ b/src/ai/ai_config.cpp @@ -75,9 +75,9 @@ AIInfo *AIConfig::GetInfo() const return this->info; } -bool AIConfig::ResetInfo() +bool AIConfig::ResetInfo(bool force_exact_match) { - this->info = AI::FindInfo(this->name, -1, false); + this->info = AI::FindInfo(this->name, force_exact_match ? this->version : -1, force_exact_match); return this->info != NULL; } |