Commit Graph

25351 Commits

Author SHA1 Message Date
Oliver Stöneberg dafb2fe6a0
Test GUI build CMake in CI (#3621) 2021-12-15 19:36:34 +01:00
Paul Fultz II 16110b6157
Fix 10339: Lambda in leads to analysis fail (#3629) 2021-12-15 19:34:18 +01:00
Paul Fultz II 5f73af0d0e
Fix 10625: False positive: known value below do while (#3623) 2021-12-15 19:32:14 +01:00
Paul Fultz II 6681576707
Fix 10642: False positive: Possible dereference of an invalid iterator: v.begin()+v.size()-1 (#3630) 2021-12-15 19:31:28 +01:00
Daniel Marjamäki d2dd4e54b9 Fix execution of executable addons from GUI 2021-12-15 19:27:02 +01:00
orbitcowboy 48ab3f762b wxwidgets.cfg: Added support for more interfaces 2021-12-15 13:39:14 +01:00
orbitcowboy a84bce2266 wxwidgets.cfg: Added support for more interfaces 2021-12-15 13:29:23 +01:00
orbitcowboy 1dff1af199 wxwidgets.cfg: Added support for 'wxTextEntry::GetRange' 2021-12-15 13:12:36 +01:00
orbitcowboy 04f18a8251 wxwidgets.cfg: Added support for more interfaces 2021-12-15 13:07:40 +01:00
orbitcowboy 3ffc941783 wxwidgets.cfg: Added support for 'wxTextCtrl::GetStyle' 2021-12-15 13:02:17 +01:00
Daniel Marjamäki cf203e2285 misra; fix typo 2021-12-14 17:32:05 +01:00
chrchr-github 532477cdb2
Fix #9549 FP knownConditionTrueFalse (bitshift) (#3616) 2021-12-14 07:30:57 +01:00
Paul Fultz II cb2738a60c
Fix 10645: FP knownEmptyContainer after conditional return (#3620) 2021-12-14 07:22:57 +01:00
Oliver Stöneberg f79bb40e3d
scriptcheck.yml: avoid duplicated cppcheck builds (#3611) 2021-12-11 15:21:39 +01:00
Daniel Marjamäki 77434d093e SymbolDatabase: Do not set wrong type for std::map etc items in range for loop 2021-12-11 15:16:54 +01:00
Oliver Stöneberg 54b54567cf
astutils.cpp: optimized isSameExpression() a bit - reduces average Ir from 294 to 213 when analyzing test folder (#3528) 2021-12-11 15:10:15 +01:00
Daniel Marjamäki d0e68e0d77 misra; add rule 17.3 2021-12-11 12:42:15 +01:00
chrchr-github f64097465f
Fix #9342 FP oppositeExpression - negated value is not opposite for bitwise logical operators (#3615) 2021-12-10 18:06:45 +01:00
Rikard Falkeborn e7b6920cf4
Fix #10600: FP invalid dealloc of function array argument (#3613)
Do not warn for array arguments that are free'd, since they decay to
pointers.
2021-12-09 07:16:40 +01:00
orbitcowboy bca27bf7d2 Ticket #6098, added regression test 2021-12-07 08:50:29 +01:00
chrchr-github 33c55f77a8
Fix #9570 (#3608) 2021-12-07 07:44:07 +01:00
Paul Fultz II 3874c546cc
Fix 10641: FP invalidLifetime with compiler-generated constructor (#3609) 2021-12-07 07:43:25 +01:00
Paul Fultz II 0be6e27231
Fix 10640: FN nullPointerRedundantCheck (#3607)
* Fix 10640: FN nullPointerRedundantCheck

* Format
2021-12-06 20:06:48 +01:00
Paul Fultz II d2926bfa96
ValueFlow: Propagate const variables more aggressively (#3606)
* ValueFlow: Propagate const variables more aggressively

* Format

* Fix incorrect addition
2021-12-06 09:16:42 +01:00
Rikard Falkeborn 5fd17ef2c2
test-my-pr: Allow to specify packages to process (#3605) 2021-12-05 20:25:38 +01:00
orbitcowboy 97f84a368d Ticket #8648: Added regression test. 2021-12-05 17:44:57 +01:00
Rikard Falkeborn 1a50146745
autovarInvalidDeallocation: Fix fp with impossible value (#3604)
daca reports new false positives after db4f94fdfe on the form:

	void f() {
	    char *ptr = malloc(10);
	    char *empty_str = "";
	    if (ptr == NULL)
	        ptr = empty_str;
	    if (ptr != empty_str)
	        free(ptr);
	}

Add a check that the value is not impossible to avoid this.
2021-12-05 15:47:21 +01:00
Paul Fultz II f64bcac004
Fix 10429: Regression: invalidIterator (#3603) 2021-12-05 15:46:52 +01:00
Paul Fultz II c0af66bb52
Fix 10552: Internal error with unusedFunction (#3600) 2021-12-05 15:46:17 +01:00
Paul Fultz II 35f14962fc
Regression test for 9523: Syntax Error: AST broken, 'if' doesn't have two operands. (#3602) 2021-12-04 17:03:02 +01:00
Paul Fultz II a03e731930
Track lifetimes of lambdas that capture the 'this' variable (#3594) 2021-12-04 17:00:55 +01:00
orbitcowboy 9ddc7f2d71 windows.cfg: Added support for _dupenv_s() and _wdupenv_s() 2021-12-04 16:32:22 +01:00
Paul Fultz II 29dbded4af
Fix 10615: Crash in Token::linkAt (#3599) 2021-12-04 12:57:59 +01:00
Paul Fultz II bc31419da0
Fix 9301: Syntax error when specializing template variable array (#3601) 2021-12-04 12:56:25 +01:00
Paul Fultz II 8dcea26c10
Find iterator mismatch when using temporary containers (#3579) 2021-12-04 12:55:56 +01:00
Paul Fultz II c14920218c
Fix 10624: FP knownConditionTrueFalse with pointer member and dynamic cast (#3598) 2021-12-04 08:54:24 +01:00
Paul Fultz II a0d633945e
Fix 10621: FP arrayIndexOutOfBoundsCond with multiple index checks (#3597)
* Fix 10621: FP arrayIndexOutOfBoundsCond with multiple index checks

* Format
2021-12-04 08:54:04 +01:00
orbitcowboy 19006ab775 std.cfg: Added support for string::shrink_to_fit() 2021-12-03 14:36:30 +01:00
chrchr-github b6b2cf8283
Add tests, todo for #9291, #9949 (#3593) 2021-12-02 17:28:31 +01:00
chrchr-github 6f2000a99b
Add test for #9126 (#3592) 2021-12-01 18:24:25 +01:00
chrchr-github 4a1a1534df
Fix #10632 (FN charset in format string) (#3590)
* Fix #10632

* Typo
2021-12-01 09:51:48 +01:00
Rikard Falkeborn db4f94fdfe
Fix #7341: Dealloc string literal (#3586) 2021-11-30 07:31:28 +01:00
chrchr-github d565cde815
Fix and tests for #7622, #10381, #10382 (#3588)
* Add test cases for #10381, #10382

* Fix #7622

* Format
2021-11-29 22:51:35 +01:00
Daniel Marjamäki 396a69a630 Clang: do not silently abort from checks 2021-11-29 20:09:39 +01:00
chrchr-github b4a60305f9
Add todo for #9827 (#3589) 2021-11-29 19:12:07 +01:00
chrchr-github ca311ebcdf
ASSERT() on calls to Tokenizer::tokenize() in test code (#3501) 2021-11-29 07:34:39 +01:00
Paul Fultz II 853a1f6d54
Fix 10631: FP, Regression: error: Return value of allocation function 'makeThing' is not stored. (#3585) 2021-11-29 07:06:43 +01:00
Daniel Marjamäki c26e205e29 clang import: fixed problem with nameless struct 2021-11-29 07:00:18 +01:00
Paul Fultz II 57f5b19b34
Fix 7812: False negative: return pointer of local variable (#3583)
* Fix 7812: False negative: return pointer of local variable

* Format

* Add test case for 3029

* Format
2021-11-28 15:25:21 +01:00
chrchr-github cea649761c
Fix FN buffer overrun with array of pointers (#3582) 2021-11-27 12:15:36 +01:00