Commit Graph

25 Commits

Author SHA1 Message Date
Daniel Marjamäki 6874f27e73 Added CHECK_WRONG_DATA() that can be used to avoid crashes/hangs in release binaries 2017-03-26 11:23:39 +02:00
Daniel Marjamäki 5d7fa590af Don't check ignored function return value in ({..}). Ticket: #7934 2017-03-08 10:23:38 +01:00
Daniel Marjamäki 5ea9519586 UseRetVal: Fix FN for methods 2017-03-05 22:23:16 +01:00
Daniel Marjamäki ecc59859e1 Don't simplify _Bool in TokenList 2017-03-04 11:13:28 +01:00
Daniel Marjamäki 774a8979a3 Fixed #7095 (False positive: (warning) Return value of function to_string() is not used.) 2017-02-12 16:50:45 +01:00
Daniel Marjamäki 7c800d6ed7 Fixed #7447 (FP: ignoredReturnValue on C++11 uniform initialization) 2017-02-12 16:33:28 +01:00
amai2012 0bec604627 Repair CWE mapping for calling obsolete functions 2016-08-04 13:55:38 +02:00
PKEuS dde6f5eaea Do not warn about alloca() in C89 mode (#7558) 2016-06-20 09:30:41 +02:00
Roberto Martelloni dce7128f30 CWE mapping of duplicateExpression, duplicateBreak (CWE561), unreachableCode, unsignedLessThanZero, unsignedPositive, pointerLessThanZero, pointerPositive, varFuncNullUB, nanInArithmeticExpression, commaSeparatedReturn, (#797)
ignoredReturnValue
2016-05-22 13:17:38 +02:00
Roberto Martelloni afa8ad0ebe CWE mapping of selfAssignment, wrongmathcall, unpreciseMathCall, memsetZeroBytes, memsetFloat, memsetValueOutOfRange, clarifyCalculation, clarifyStatement 2016-05-14 10:13:33 +01:00
amai2012 f5e8a72dc2 #7438 Incorrect alloca() avoidance suggestion 2016-04-08 11:21:53 +02:00
Daniel Marjamäki 5e10e680da CWE: refactoring. use constants instead of magic numbers. 2016-01-25 20:01:48 +01:00
Roberto Martelloni 5ce69da02d Mapped 26 errors to their CWEs ID. 2016-01-24 20:53:05 +00:00
Lauri Nurmi 996c9244d8 Update copyright year to 2007-2016. 2016-01-01 15:34:45 +02:00
Daniel Marjamäki 34449ae857 Use simpleMatch instead of Match for simple pattern, hope this makes Travis happy 2015-12-26 02:21:52 +01:00
Daniel Marjamäki cea40168e0 Code fix. Used wrong variable in condition, leading to segfaults. 2015-12-26 01:52:43 +01:00
Daniel Marjamäki 293bd2eead Fixed #6990 (false negative: Invalid abs() argument nr 1. A non-boolean value is required.) 2015-12-26 01:38:41 +01:00
PKEuS 940d569980 Refactorization: Removed redundant %any% patterns. 2015-12-24 14:40:48 +01:00
Dmitry-Me 7303790a73 Pre-check to reduce number of match checks 2015-12-24 13:07:47 +03:00
Matthias Krüger 87ce88d6ab CheckFunctions::checkProhibitedFunctions(): don't warn about alloca when --enable=warning is not given. 2015-11-25 22:05:51 +01:00
Benjamin Bannier e84fe33ad0 Include cmath for std::fabs 2015-11-25 10:16:41 +01:00
Alexander Mai b7030fcfa1 Fix compiler error (VS2010) and warning 2015-11-22 16:56:44 +01:00
PKEuS f516de8633 Moved a few checks from CheckOther to CheckFunctions 2015-11-22 13:49:10 +01:00
Matthias Krüger a610ef9ce8 fix internal warning:
[lib/checkfunctions.cpp:44]: (warning) Found simple pattern inside Token::Match() call: "alloca ("
2015-11-22 11:00:36 +01:00
PKEuS 57d1196386 Replaced CheckNonReentrantFunctions and CheckObsoleteFunctions by generic CheckFunctions which is based on Library (#6529) 2015-11-22 09:18:07 +01:00