From 72c2f400b1b1dc6a5edab397f964d0d37f86f7fa Mon Sep 17 00:00:00 2001 From: Pierre Schweitzer Date: Sat, 31 Mar 2012 13:14:24 +0200 Subject: [PATCH] Fix a memory leak and a performance issue in checkExecutionPaths() --- lib/executionpath.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/executionpath.cpp b/lib/executionpath.cpp index d8a4300e1..120a29d40 100644 --- a/lib/executionpath.cpp +++ b/lib/executionpath.cpp @@ -471,7 +471,7 @@ void checkExecutionPaths(const SymbolDatabase *symbolDatabase, ExecutionPath *c) c->end(checks, i->classEnd); // Cleanup - while (checks.size() > 1) { + while (!checks.empty()) { delete checks.back(); checks.pop_back(); }