From 187b887698282d2443d88a425ae3147c2da06620 Mon Sep 17 00:00:00 2001 From: Steve Date: Sat, 3 Feb 2018 16:21:53 +0000 Subject: [PATCH] Free data. --- src/world/worldLoader.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/world/worldLoader.c b/src/world/worldLoader.c index 016b552..f88e5de 100644 --- a/src/world/worldLoader.c +++ b/src/world/worldLoader.c @@ -63,6 +63,10 @@ void loadWorld(char *filename) loadEntities(cJSON_GetObjectItem(root, "entities")); loadObjectives(cJSON_GetObjectItem(root, "objectives")); + + cJSON_Delete(root); + + free(text); } static void loadEnemyTypes(char *enemyTypes)