From c61bff46d7c6ead7027f26fe412a7d71befed8a8 Mon Sep 17 00:00:00 2001 From: Yamagi Burmeister Date: Sat, 17 Dec 2016 10:00:40 +0100 Subject: [PATCH] Don't leak unknown entities. I don't think that this has a visible effect, because there shouldn't be any unknown entities in maps creates with the official entities.def. This was reported by maraakate in quake2 issue #160. --- src/g_spawn.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/g_spawn.c b/src/g_spawn.c index 000fe0b..9e3781b 100644 --- a/src/g_spawn.c +++ b/src/g_spawn.c @@ -350,6 +350,7 @@ ED_CallSpawn(edict_t *ent) if (!ent->classname) { gi.dprintf("ED_CallSpawn: NULL classname\n"); + G_FreeEdict(ent); return; }