From: havoc Date: Sun, 20 Dec 2009 06:22:59 +0000 (+0000) Subject: avoid a permanent memory leak on lightmap allocation in q1bsp - no time X-Git-Tag: xonotic-v0.1.0preview~1055 X-Git-Url: http://git.xonotic.org/?a=commitdiff_plain;h=c21f259c8c6184f3a89274d0a388109109f669e3;p=xonotic%2Fdarkplaces.git avoid a permanent memory leak on lightmap allocation in q1bsp - no time to investigate the underlying cause git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9592 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/model_shared.c b/model_shared.c index 040b1ba0..771aa39b 100644 --- a/model_shared.c +++ b/model_shared.c @@ -2942,7 +2942,7 @@ void Mod_AllocLightmap_Init(mod_alloclightmap_state_t *state, int width, int hei state->width = width; state->height = height; state->currentY = 0; - state->rows = Mem_Alloc(tempmempool, state->height * sizeof(*state->rows)); + state->rows = Mem_Alloc(loadmodel->mempool, state->height * sizeof(*state->rows)); for (y = 0;y < state->height;y++) { state->rows[y].currentX = 0;