From 05f16a25afc080e59481805e211d6e567aedc09e Mon Sep 17 00:00:00 2001 From: Edoardo Prezioso Date: Fri, 6 Jan 2012 15:15:52 +0100 Subject: [PATCH] Fixed ticket #2405 (debug messages provide incorrect file:line information) --- lib/checkmemoryleak.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/checkmemoryleak.cpp b/lib/checkmemoryleak.cpp index fe41cf3c4..3b5d6bae9 100644 --- a/lib/checkmemoryleak.cpp +++ b/lib/checkmemoryleak.cpp @@ -2180,7 +2180,7 @@ void CheckMemoryLeakInFunction::checkScope(const Token *Tok1, const std::string errmsg << "inconclusive leak of " << varname << ": "; for (const Token *tok2 = tok; tok2; tok2 = tok2->next()) errmsg << " " << tok2->str(); - reportError(_tokenizer->tokens(), Severity::debug, "debug", errmsg.str()); + reportError(first, Severity::debug, "debug", errmsg.str()); } }