CheckMemoryLeak: Bug fix.

This commit is contained in:
Daniel Marjamäki 2007-06-03 17:09:15 +00:00
parent 7a8ee64068
commit eade228c24
1 changed files with 18 additions and 9 deletions

View File

@ -84,19 +84,28 @@ void CheckMemoryLeak()
} }
// if level.. // if level..
if ( ! iflist.empty() )
{
if (iflist.back()) if (iflist.back())
iflevel--; iflevel--;
iflist.pop_back(); iflist.pop_back();
}
// loop level.. // loop level..
if ( ! looplist.empty() )
{
if (looplist.back()) if (looplist.back())
looplevel--; looplevel--;
looplist.pop_back(); looplist.pop_back();
}
// switch level.. // switch level..
if ( ! switchlist.empty() )
{
if (switchlist.back()) if (switchlist.back())
switchlevel--; switchlevel--;
switchlist.pop_back(); switchlist.pop_back();
}
// Make sure the varlist is empty.. // Make sure the varlist is empty..
if (indentlevel <= 1) if (indentlevel <= 1)