Memory leak: Fixed one more unit test
This commit is contained in:
parent
3a39259472
commit
f347efd802
|
@ -788,6 +788,11 @@ void CheckMemoryLeakClass::CheckMemoryLeak_CheckScope( const TOKEN *Tok1, const
|
|||
MemoryLeak(Tokenizer::gettok(findmatch(tok, "alloc ; if continue ;"), 3), varname);
|
||||
}
|
||||
|
||||
else if ( findmatch(tok, "alloc ; if break ;") )
|
||||
{
|
||||
MemoryLeak(Tokenizer::gettok(findmatch(tok, "alloc ; if break ;"), 3), varname);
|
||||
}
|
||||
|
||||
else if ( findmatch(tok, "alloc ; if return ;") )
|
||||
{
|
||||
MemoryLeak(Tokenizer::gettok(findmatch(tok, "alloc ; if return ;"), 3), varname);
|
||||
|
|
|
@ -51,7 +51,7 @@ private:
|
|||
// Check for memory leaks..
|
||||
ShowAll = false;
|
||||
FillFunctionList(0);
|
||||
CheckMemoryLeakClass checkMemoryLeak;
|
||||
CheckMemoryLeakClass checkMemoryLeak;
|
||||
checkMemoryLeak.CheckMemoryLeak();
|
||||
|
||||
tokenizer.DeallocateTokens();
|
||||
|
@ -89,7 +89,7 @@ private:
|
|||
TEST_CASE( forwhile4 );
|
||||
TEST_CASE( forwhile5 );
|
||||
TEST_CASE( forwhile6 );
|
||||
// TODO TEST_CASE( forwhile7 );
|
||||
TEST_CASE( forwhile7 );
|
||||
|
||||
TEST_CASE( dowhile1 );
|
||||
|
||||
|
@ -494,7 +494,6 @@ private:
|
|||
|
||||
void forwhile7()
|
||||
{
|
||||
// TODO
|
||||
check("void f()\n"
|
||||
"{\n"
|
||||
" for (int i = 0; i < j; i++)\n"
|
||||
|
|
Loading…
Reference in New Issue