summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2008-01-16 16:52:50 +0000
committerpeter1138 <peter1138@openttd.org>2008-01-16 16:52:50 +0000
commit019ffe29b8f82b4775e54e94c9b1fdb27ee647f8 (patch)
tree082993db3f89fc518f76bd6eebd9c359fd1513fd
parent692fbb3c053e150a3d222e0f3da05f9913467eb7 (diff)
downloadopenttd-019ffe29b8f82b4775e54e94c9b1fdb27ee647f8.tar.xz
(svn r11878) -Fix: Crash in MP in vehicle group window if the currently selected group is deleted by another player.
-rw-r--r--src/group_gui.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/group_gui.cpp b/src/group_gui.cpp
index 9e97db1be..1d74002c3 100644
--- a/src/group_gui.cpp
+++ b/src/group_gui.cpp
@@ -299,6 +299,7 @@ static void GroupWndProc(Window *w, WindowEvent *e)
case WE_INVALIDATE_DATA:
gv->l.flags |= VL_REBUILD;
gl->l.flags |= VL_REBUILD;
+ if (!IsValidGroupID(gv->group_sel)) gv->group_sel = ALL_GROUP;
UpdateGroupActionDropdown(w, gv->group_sel);
SetWindowDirty(w);
break;