Null pointer: Changed 'possible null pointer dereference - otherwise condition is redundant' to warning

This commit is contained in:
Daniel Marjamki 2013-02-02 15:46:29 +01:00
parent 75e20a996d
commit abd536b84c
2 changed files with 8 additions and 4 deletions

View File

@ -1104,9 +1104,13 @@ void CheckNullPointer::nullPointerByCheckAndDeRef()
void CheckNullPointer::nullPointer() void CheckNullPointer::nullPointer()
{ {
nullPointerLinkedList(); nullPointerLinkedList();
if (_settings->isEnabled("warning")) {
nullPointerStructByDeRefAndChec(); nullPointerStructByDeRefAndChec();
nullPointerByDeRefAndChec(); nullPointerByDeRefAndChec();
nullPointerByCheckAndDeRef(); nullPointerByCheckAndDeRef();
}
nullPointerDefaultArgument(); nullPointerDefaultArgument();
} }

View File

@ -81,7 +81,7 @@ private:
errout.str(""); errout.str("");
Settings settings; Settings settings;
settings.addEnabled("style"); settings.addEnabled("warning");
settings.inconclusive = inconclusive; settings.inconclusive = inconclusive;
// Tokenize.. // Tokenize..