summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2007-07-13 15:02:22 +0000
committertruelight <truelight@openttd.org>2007-07-13 15:02:22 +0000
commit84303d03969efa5432fb307528a34f5e274c0649 (patch)
tree9980943a19d393c04269ca5d40811ba1866ed2c7 /src
parentfe952911f5e58fe3300b1e40f306413bd5ee1af3 (diff)
downloadopenttd-84303d03969efa5432fb307528a34f5e274c0649.tar.xz
(svn r10548) -Fix [FS#1020]: don't segfault when you quit in the end-of-the-game screen
Diffstat (limited to 'src')
-rw-r--r--src/main_gui.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main_gui.cpp b/src/main_gui.cpp
index 645329c72..8c06ccacd 100644
--- a/src/main_gui.cpp
+++ b/src/main_gui.cpp
@@ -1700,7 +1700,7 @@ static void MainToolbarWndProc(Window *w, WindowEvent *e)
}
case WE_MESSAGE:
- HandleZoomMessage(w, FindWindowById(WC_MAIN_WINDOW, 0)->viewport, 17, 18);
+ if (FindWindowById(WC_MAIN_WINDOW, 0) != NULL) HandleZoomMessage(w, FindWindowById(WC_MAIN_WINDOW, 0)->viewport, 17, 18);
break;
}
}