summaryrefslogtreecommitdiff
path: root/src/highscore_gui.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-02-23 01:51:19 +0000
committerrubidium <rubidium@openttd.org>2009-02-23 01:51:19 +0000
commit2a2ee1fdb903ef56e2410be0363f23b399314dc0 (patch)
tree29d41ddc390831e9711050ccb7ba7c0230c27f86 /src/highscore_gui.cpp
parent5c27b42a778d93c7664eef8f576524ebf10f20e6 (diff)
downloadopenttd-2a2ee1fdb903ef56e2410be0363f23b399314dc0.tar.xz
(svn r15554) -Fix: -v null crashing in 2051 due to trying to show the high score of the spectator.
Diffstat (limited to 'src/highscore_gui.cpp')
-rw-r--r--src/highscore_gui.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/highscore_gui.cpp b/src/highscore_gui.cpp
index d6400bb6a..372e5553b 100644
--- a/src/highscore_gui.cpp
+++ b/src/highscore_gui.cpp
@@ -193,8 +193,8 @@ void ShowHighscoreTable(int difficulty, int8 ranking)
* if it was high enough */
void ShowEndGameChart()
{
- /* Dedicated server doesn't need the highscore window */
- if (_network_dedicated) return;
+ /* Dedicated server doesn't need the highscore window and neither does -v null. */
+ if (_network_dedicated || (!_networking && !IsValidCompanyID(_local_company))) return;
HideVitalWindows();
DeleteWindowByClass(WC_ENDSCREEN);