cppcheck/test
John Marshall 297efcd049 Avoid some additional memleakOnRealloc false positives (#2422)
* Avoid some additional memleakOnRealloc false positives

checkReallocUsage() already contains code to suppress the
`p = realloc(p, size)` error message when the pointer has been
previously copied from another variable (hence there is an additional
copy of the original pointer value) within the same function, as in
the added realloc21() test case.

Extend this so that `p = *pp` and `p = ptr->foo` are also recognized
as copies from another variable with the same original pointer value,
as in the added realloc22() and realloc23() test cases.

* Rewrite as a single findmatch() expression
2019-12-04 12:13:44 +01:00
..
cfg Fix incorrect usage of "unlikely" hint 2019-11-27 18:08:10 +03:00
cli Fixed #9464 (Import compile database; only check given configuration) 2019-11-09 17:51:42 +01:00
synthetic Improve Python code 2017-06-05 13:23:00 +02:00
testsuites Typos found by running "codespell" (#1804) 2019-04-23 13:26:48 +02:00
verify Verify: Fix a false negative in the itc test suite 2019-10-25 21:46:02 +02:00
CMakeLists.txt Enhance handling of assertion from googletest (#2331) 2019-11-06 21:38:01 +01:00
options.cpp Update Copyright 2019-06-29 07:49:14 +02:00
options.h Update Copyright 2019-06-29 07:49:14 +02:00
redirect.h Updated copyright year 2018-01-14 15:37:52 +01:00
test.cxx
test64bit.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testassert.cpp Moved CheckAssert::assertWithSideEffects to normal checking 2019-03-09 16:50:50 +01:00
testastutils.cpp Improve test coverage for testing AST 2019-11-28 18:11:55 +03:00
testautovariables.cpp Fix issue 9482: False positive: Reference to temporary returned using trailing return type (#2413) 2019-12-01 15:10:02 +01:00
testbool.cpp Fix false negatives in checkBitwiseOnBoolean (#2220) 2019-10-06 09:57:31 +02:00
testboost.cpp CheckBoost: Use 'normal' checking 2019-03-09 20:00:31 +01:00
testbufferoverrun.cpp Regression for issue 8653: valueFlowAfterCondition: compound conditional (#2416) 2019-12-02 11:35:51 +01:00
testcharvar.cpp Remove test case, ValueFlow will truncate and sign-extend values 2019-05-01 19:33:47 +02:00
testclass.cpp Remove 'unsafeClassDivZero' warning. The software verification will cover this better. 2019-11-10 16:49:34 +01:00
testcmdlineparser.cpp Convert SHOWTIME_MODES to enum class 2019-07-31 22:35:51 +02:00
testcondition.cpp Fixed #9285 (Misleading warning message) 2019-11-16 17:24:54 +01:00
testconstructors.cpp Revert "#9391 Detecting uninited member variables with default ctor (#2249)" 2019-10-09 08:17:47 +02:00
testcppcheck.cpp added missing OVERRIDE usage and removed redundant virtual (#2190) 2019-09-20 21:57:16 +02:00
testerrorlogger.cpp Fixed #9260 (--template=gcc does not work correctly with -j) 2019-08-18 16:33:32 +02:00
testexceptionsafety.cpp Use 'normal' checking instead of 'simplified' 2019-03-16 07:19:48 +01:00
testexprengine.cpp ExprEngine: Improved handling of struct member assignments in loop 2019-10-14 19:41:32 +02:00
testfilelister.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testfunctions.cpp Improve test coverage for invalid use of bool parameters 2019-11-22 18:11:38 +03:00
testgarbage.cpp Add regression tests for fixed crashes (#2379) 2019-11-19 21:50:53 +01:00
testimportproject.cpp testrunner: Fix assertion error 2019-08-17 15:12:49 +02:00
testincompletestatement.cpp Fixed #9335 (FP constStatement "Found a statement that begins with string constant") 2019-11-28 17:49:33 +01:00
testinternal.cpp fix #8965 ("(debug) Executable scope 'x' with unknown function." with rvalue parameter in method) (#2237) 2019-10-04 12:30:11 +02:00
testio.cpp Improve test coverage for %jd used with scanf() 2019-11-20 18:10:56 +03:00
testleakautovar.cpp Add regression test for #9028 (#2343) 2019-11-10 08:28:46 +01:00
testlibrary.cpp Fix issue 9428: FP uninitvar for pointer passed to sscanf (#2344) 2019-11-13 12:46:54 +01:00
testmathlib.cpp Keep prefix in string and char literals (#2272) 2019-10-16 11:41:33 +02:00
testmemleak.cpp Avoid some additional memleakOnRealloc false positives (#2422) 2019-12-04 12:13:44 +01:00
testnullpointer.cpp Fix issue 9196: Lambda confuses check (#2415) 2019-12-03 18:30:52 +01:00
testoptions.cpp Allow multiple test case arguments to testrunner (#1755) 2019-03-26 20:28:40 +01:00
testother.cpp Fixx issue 9355: FP constParameter when returning non-const reference to struct member (#2373) 2019-11-18 06:39:50 +01:00
testpath.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testpathmatch.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testplatform.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testpostfixoperator.cpp Valid code for incrementing raw pointer (#2418) 2019-12-03 18:33:05 +01:00
testpreprocessor.cpp use range loops / constness (#2181) 2019-09-19 20:29:33 +02:00
testrunner.cpp Update Copyright 2019-06-29 07:49:14 +02:00
testrunner.vcxproj Windows testrunner: Add testexprengine.cpp (#2184) 2019-09-19 19:40:00 +02:00
testrunner.vcxproj.filters Windows testrunner: Add testexprengine.cpp (#2184) 2019-09-19 19:40:00 +02:00
testsamples.cpp Remove unneeded string copy 2019-11-19 10:19:13 +03:00
testsimplifytemplate.cpp fix #9495 (Crash when parsing angle brackets in template with type traits (assertion failure)) (#2407) 2019-11-29 09:44:27 +01:00
testsimplifytokens.cpp Token::ConcatStr(): Handle mixed string literals (#2337) 2019-11-08 08:03:45 +01:00
testsimplifytypedef.cpp Fix #9446 (Syntax error on valid C++ code) (#2316) 2019-11-01 09:11:29 +01:00
testsimplifyusing.cpp fix using type aliases in out of class destructors (#2250) 2019-10-08 19:30:41 +02:00
testsizeof.cpp Improve test coverage 2019-11-01 18:41:10 +03:00
teststl.cpp Fix crash 9492: Crash in FwdAnalysis::checkRecursive() (condTok is nullptr) (#2411) 2019-12-01 14:53:03 +01:00
teststring.cpp Set correct type and size of string and char literals (#2275) 2019-10-20 07:11:57 +02:00
testsuite.cpp use range loops / constness (#2181) 2019-09-19 20:29:33 +02:00
testsuite.h Warn about unknown macro causing template syntax error (#2222) 2019-09-26 16:01:01 +02:00
testsuppressions.cpp Various clang-tidy fixes (#2192) 2019-09-25 15:25:19 +02:00
testsymboldatabase.cpp Fixed #9449 (SymbolDatabase: Function lookup fails when string literal is converted to bool) 2019-10-30 21:05:42 +01:00
testthreadexecutor.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testtimer.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testtoken.cpp Token::ConcatStr(): Handle mixed string literals (#2337) 2019-11-08 08:03:45 +01:00
testtokenize.cpp Fix crash 9492: Crash in FwdAnalysis::checkRecursive() (condTok is nullptr) (#2411) 2019-12-01 14:53:03 +01:00
testtokenlist.cpp Update copyright year 2019-02-09 07:24:06 +01:00
testtype.cpp Fix severity of c++14 shifts with too many bits (#2213) 2019-09-25 20:16:04 +02:00
testuninitvar.cpp Fixed #9422 (FP uninitdata - writing pointer to output stream) 2019-11-16 11:47:57 +01:00
testunusedfunctions.cpp TestSuite: The ASSERT and ASSERT_EQUALS will now stop executing the test case upon failure. This can be used to avoid extra guard logic in tests. 2019-09-16 06:34:45 +02:00
testunusedprivfunc.cpp Run more tests on full token list (#2020) 2019-07-22 10:26:55 +02:00
testunusedvar.cpp Improved fix for #8978 (False positive: Variable assigned value that is never used when assigning via iterator) 2019-11-17 12:08:21 +01:00
testutils.h added missing OVERRIDE usage and removed redundant virtual (#2190) 2019-09-20 21:57:16 +02:00
testvaarg.cpp Disable all simplified checks 2019-03-16 09:17:50 +01:00
testvalueflow.cpp Fix issue 9458: Crash with shadow variables in a lambda (#2406) 2019-11-29 09:45:02 +01:00
testvarid.cpp Fix #9383 ("debug: Function::addArguments found argument 'x' with varid 0." with variadic templates) (#2238) 2019-10-06 12:45:42 +02:00