@@ -1794,7 +1794,7 @@ void ExprEngine::executeFunction(const Scope *functionScope, const Tokenizer *to
17941794 }
17951795 }
17961796
1797- // Write a verification report
1797+ // Write a report
17981798 if (bugHuntingReport) {
17991799 report << " [function-report] "
18001800 << Path::stripDirectoryPart (tokenizer->list .getFiles ().at (functionScope->bodyStart ->fileIndex ())) << " :"
@@ -1827,7 +1827,7 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
18271827 if (tok->astParent ()->astOperand2 () == tok && value.isEqual (dataBase, 0 )) {
18281828 dataBase->addError (tok->linenr ());
18291829 std::list<const Token*> callstack{tok->astParent ()};
1830- const char * const id = (tok->valueType () && tok->valueType ()->isFloat ()) ? " verificationDivByZeroFloat " : " verificationDivByZero " ;
1830+ const char * const id = (tok->valueType () && tok->valueType ()->isFloat ()) ? " bughuntingDivByZeroFloat " : " bughuntingDivByZero " ;
18311831 ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, id, " There is division, cannot determine that there can't be a division by zero." , CWE (369 ), false );
18321832 errorLogger->reportErr (errmsg);
18331833 }
@@ -1877,7 +1877,7 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
18771877 errorMessage += " Note that unsigned integer overflow is defined and will wrap around." ;
18781878
18791879 std::list<const Token*> callstack{tok};
1880- ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " verificationIntegerOverflow " , errorMessage, false );
1880+ ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " bughuntingIntegerOverflow " , errorMessage, false );
18811881 errorLogger->reportErr (errmsg);
18821882 };
18831883#endif
@@ -1943,7 +1943,7 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
19431943
19441944 dataBase->addError (tok->linenr ());
19451945 std::list<const Token*> callstack{tok};
1946- ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " verificationUninit " , " Cannot determine that '" + tok->expressionString () + " ' is initialized" , CWE_USE_OF_UNINITIALIZED_VARIABLE, false );
1946+ ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " bughuntingUninit " , " Cannot determine that '" + tok->expressionString () + " ' is initialized" , CWE_USE_OF_UNINITIALIZED_VARIABLE, false );
19471947 errorLogger->reportErr (errmsg);
19481948 };
19491949#endif
@@ -1991,7 +1991,7 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
19911991 ErrorLogger::ErrorMessage errmsg (callstack,
19921992 &tokenizer->list ,
19931993 Severity::SeverityType::error,
1994- " verificationInvalidArgValue " ,
1994+ " bughuntingInvalidArgValue " ,
19951995 " There is function call, cannot determine that " + std::to_string (num) + getOrdinalText (num) + " argument value meets the attribute " + bad, CWE (0 ), false );
19961996 errorLogger->reportErr (errmsg);
19971997 return ;
@@ -2040,7 +2040,7 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
20402040 if (err) {
20412041 dataBase->addError (tok->linenr ());
20422042 std::list<const Token*> callstack{tok};
2043- ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " verificationInvalidArgValue " , " There is function call, cannot determine that " + std::to_string (num) + getOrdinalText (num) + " argument value is valid. Bad value: " + bad, CWE (0 ), false );
2043+ ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " bughuntingInvalidArgValue " , " There is function call, cannot determine that " + std::to_string (num) + getOrdinalText (num) + " argument value is valid. Bad value: " + bad, CWE (0 ), false );
20442044 errorLogger->reportErr (errmsg);
20452045 break ;
20462046 }
@@ -2055,7 +2055,7 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
20552055 if (v.second ->isUninit ()) {
20562056 dataBase->addError (tok->linenr ());
20572057 std::list<const Token*> callstack{tok};
2058- ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " verificationUninitArg " , " There is function call, cannot determine that " + std::to_string (num) + getOrdinalText (num) + " argument is initialized." , CWE_USE_OF_UNINITIALIZED_VARIABLE, false );
2058+ ErrorLogger::ErrorMessage errmsg (callstack, &tokenizer->list , Severity::SeverityType::error, " bughuntingUninitArg " , " There is function call, cannot determine that " + std::to_string (num) + getOrdinalText (num) + " argument is initialized." , CWE_USE_OF_UNINITIALIZED_VARIABLE, false );
20592059 errorLogger->reportErr (errmsg);
20602060 break ;
20612061 }
@@ -2079,5 +2079,5 @@ void ExprEngine::runChecks(ErrorLogger *errorLogger, const Tokenizer *tokenizer,
20792079 if (settings->bugHuntingReport .empty ())
20802080 std::cout << report.str ();
20812081 else if (errorLogger)
2082- errorLogger->reportVerification (report.str ());
2082+ errorLogger->bughuntingReport (report.str ());
20832083}
0 commit comments