From 67bbd8f7ab94407684bd2a8de1c610710fb68528 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 18 Nov 2007 16:41:25 +0000 Subject: (svn r11463) -Fix: some OSes seem not to handle allocating 0 bytes in the same manner as others do. --- src/group_gui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/group_gui.cpp b/src/group_gui.cpp index 1ecb8172b..807039133 100644 --- a/src/group_gui.cpp +++ b/src/group_gui.cpp @@ -40,7 +40,7 @@ static void BuildGroupList(grouplist_d* gl, PlayerID owner, VehicleType vehicle_ const Group *g; uint n = 0; - if (!(gl->l.flags & VL_REBUILD)) return; + if (!(gl->l.flags & VL_REBUILD) || GetGroupArraySize() == 0) return; list = MallocT(GetGroupArraySize()); if (list == NULL) { -- cgit v1.2.3-70-g09d2