From e05ac1be84901b4cdc116e6ed7cbd6ab761ec296 Mon Sep 17 00:00:00 2001 From: sezero Date: Sat, 19 Jun 2010 14:16:05 +0000 Subject: [PATCH] * gl_model.c (Mod_LoadFaces): Do not call GL_SubdivideSurface() in dedicated servers, otherwise we segfault in SubdividePolygon() at the BoundPoly() call. This is a workaround, the actual problem is yet to be looked into. git-svn-id: svn+ssh://svn.code.sf.net/p/quakespasm/code/trunk@185 af15c1b1-3010-417e-b628-4374ebc0bcbd --- quakespasm/Quake/gl_model.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/quakespasm/Quake/gl_model.c b/quakespasm/Quake/gl_model.c index abc3aeda..44879ef8 100644 --- a/quakespasm/Quake/gl_model.c +++ b/quakespasm/Quake/gl_model.c @@ -1035,7 +1035,12 @@ void Mod_LoadFaces (lump_t *l) { out->flags |= (SURF_DRAWTURB | SURF_DRAWTILED); Mod_PolyForUnlitSurface (out); - GL_SubdivideSurface (out); + /* FIXME: + With dedicated servers, we segfault in SubdividePolygon() at + the BoundPoly() call. The following dedicated server check is + a workaround, the actual problem is yet to be looked into. */ + if (cls.state != ca_dedicated) + GL_SubdivideSurface (out); } else if (out->texinfo->flags & TEX_MISSING) // texture is missing from bsp {