summaryrefslogtreecommitdiff
path: root/src/openttd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/openttd.cpp')
-rw-r--r--src/openttd.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp
index 035e8e5ae..235d36f01 100644
--- a/src/openttd.cpp
+++ b/src/openttd.cpp
@@ -1469,6 +1469,8 @@ void GameLoop()
ScanNewGRFFiles(_request_newgrf_scan_callback);
_request_newgrf_scan = false;
_request_newgrf_scan_callback = nullptr;
+ /* In case someone closed the game during our scan, don't do anything else. */
+ if (_exit_game) return;
}
ProcessAsyncSaveFinish();