uninitvar: removed returns from new checking to fix 'more' tests. these returns should be readded when the executionpath checking is removed.

This commit is contained in:
Daniel Marjamäki 2015-07-23 09:21:53 +02:00
parent 79067ac031
commit 8d8c03dad8
1 changed files with 2 additions and 6 deletions

View File

@ -1485,10 +1485,8 @@ bool CheckUninitVar::checkScopeForVariable(const Token *tok, const Variable& var
}
// Use variable
else if (!suppressErrors && isVariableUsage(tok, var.isPointer(), *alloc)) {
else if (!suppressErrors && isVariableUsage(tok, var.isPointer(), *alloc))
uninitvarError(tok, tok->str(), *alloc);
return true;
}
else
// assume that variable is assigned
@ -1547,10 +1545,8 @@ bool CheckUninitVar::checkScopeForVariable(const Token *tok, const Variable& var
} else {
// Use variable
if (!suppressErrors && isVariableUsage(tok, var.isPointer(), *alloc)) {
if (!suppressErrors && isVariableUsage(tok, var.isPointer(), *alloc))
uninitvarError(tok, tok->str(), *alloc);
return true;
}
else {
if (tok->strAt(1) == "=")