From 9d26f87217127ed34baf77448fa04f975f71ffa7 Mon Sep 17 00:00:00 2001 From: hikerstk Date: Mon, 10 Oct 2011 04:23:14 +0000 Subject: [PATCH] Fixed minor memory leak, and added some missing exit statements. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@9960 178a84e3-b1eb-0310-8ba1-8eac791a3b58 --- src/graphics/referee.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/graphics/referee.cpp b/src/graphics/referee.cpp index 2b2e0b9bd..10627a06f 100644 --- a/src/graphics/referee.cpp +++ b/src/graphics/referee.cpp @@ -60,6 +60,7 @@ void Referee::init() { printf("The file referee.xml does not contain a referee" "node, aborting.\n"); + exit(-1); } std::string model_filename; node->get("model", &model_filename); @@ -70,6 +71,7 @@ void Referee::init() { printf("Can't find referee model '%s', aborting.\n", model_filename.c_str()); + exit(-1); } // Translate the mesh so that the x/z middle point @@ -141,6 +143,7 @@ void Referee::init() } + delete node; } // init // ----------------------------------------------------------------------------