Commit Graph

5972 Commits

Author SHA1 Message Date
Robert Reif d12f14844a Fixed #6279 (False Positive: Member variable 'Fred::i' is not initialized in the constructor) 2014-11-20 06:18:29 +01:00
Robert Reif b7c9187539 Fixed #6280 (MathLib: binary literals are integers) 2014-11-19 06:43:52 +01:00
Alexander Mai 1c191845fb Fix invalid assertion from recent commit. Make single argument givenACodeSampleToTokenize ctor explicit. 2014-11-18 19:52:06 +01:00
PKEuS 4163f1e122 Fixed #6260 - C++11 style array initialization 2014-11-18 19:50:09 +01:00
PKEuS 428587f3d4 Fixed #6275: Simplification of = (NULL); to = 0; 2014-11-18 19:39:38 +01:00
Alexander Mai 85c02df56c Fix compiler warning. run astyle 2014-11-18 19:36:47 +01:00
PKEuS ad8749c0bd Fixed #6278: Remove casts to references to pointers in Tokenizer::simplifyCasts() 2014-11-18 19:23:59 +01:00
Alexander Mai 0ba3c15c52 Cure null pointer access within Scope::findFunction introduced by recent cs 2014-11-17 23:05:15 +01:00
Robert Reif c5e15950df Fixed #6230 (SymbolDatabase: Wrong function() is set for token) 2014-11-17 16:04:44 +01:00
Robert Reif 7c4a137e14 Fixed #6274 (MathLib::isFloat doesn't recognize long double literal suffix L or l) 2014-11-17 06:53:32 +01:00
Alexander Mai ea94b2748f #633 Adding tests for some MathLib member functions, should reach 100% function coverage now 2014-11-16 18:09:21 +01:00
Daniel Marjamäki 828417c934 CheckUnusedFunction: Refactorings to use same infrastructure for whole program analysis as CheckUninitVar and CheckBufferOverrun 2014-11-15 18:44:23 +01:00
Daniel Marjamäki de7e9223b8 Fixed #6272 (Improve check: multifile checking in checkbufferoverrun) 2014-11-15 10:43:49 +01:00
Daniel Marjamäki 149fe74d9d astyle formatting 2014-11-14 21:43:37 +01:00
orbitcowboy b9a9f51fe0 MathLib: Added test for isDec() and removed not required state. 2014-11-14 04:29:35 +01:00
Dmitry-Me cb9a6c1cb5 Don't show warning for same expressions alongside == in static_assert 2014-11-13 16:04:34 +01:00
Daniel Marjamäki 189dfd64f7 Revert "Fixed #6230 (SymbolDatabase: Wrong function() is set for token)"
This reverts commit 685fce6b91.
2014-11-11 07:29:16 +01:00
Daniel Marjamäki ea765c24f2 Fixed #3262 (Tokenizer: wrong 'return a=1,b=2,...;' simplification;) 2014-11-10 17:31:19 +01:00
Simon Martin cc6b51f2d9 Ticket #6059: Properly handle class... in parameter lists. 2014-11-07 23:08:54 +01:00
Daniel Marjamäki 685fce6b91 Fixed #6230 (SymbolDatabase: Wrong function() is set for token) 2014-11-07 11:10:20 +01:00
Robert Reif 1f32e9eee5 Symbol database: added test for findfunction 2014-11-07 10:46:31 +01:00
Daniel Marjamäki 8012ac9562 Fixed #5993 (FP: memleak (linux list)) 2014-11-07 07:44:12 +01:00
Frank Zingsheim 7e0fc3d481 Fixed #6252 (False positive "freed twice")
--HG--
extra : rebase_source : 24f801452fbefa3a59ab2cca62c3cf02aea513b6
2014-11-03 21:24:34 +01:00
PKEuS e5d63195cb Fixed #5983: Support storing pointers/references to member variables in CheckClass::checkConst() 2014-11-02 13:38:03 +01:00
Robert Reif df6855c216 SymbolDatabase: reintroduce test, move symboldatabase cleanup code to SymbolDatabase destructor 2014-11-02 10:36:52 +01:00
Frank Zingsheim 0e4c508d7b Fixed #4272 and #6237 (Crash from running out of memory with many templates) 2014-11-01 22:07:24 +01:00
Robert Reif 4eb33e7479 SymbolDatabase: Refactoring of findFunction 2014-11-01 14:36:17 +01:00
Daniel Marjamäki b766071272 Fixed #4970 (false positive: conditionally initialized variable used in if-clause (git/notes.c)) 2014-11-01 14:03:02 +01:00
PKEuS c7d315fba3 Refactorization: Changed simplifyMathFunctions() to a single pass simplifier 2014-10-31 23:08:11 +01:00
PKEuS 662283cab8 Refactorization: Avoid iterations over whole token list, limited several checks to function scopes. 2014-10-31 11:42:54 +01:00
PKEuS b5ea677180 Some fixes for CheckOther::checkIgnoredReturnValue():
- Fixed name of the function
- Fixed false positive for code like "class strcmp { strcmp() {} };"
- Fixed FP #6233 on checking side (no AST generated for function call)
2014-10-30 23:24:13 +01:00
PKEuS b7996bd0b0 Handle overloads and custom implementations of functions checkReturnIgnoredReturnValue() to avoid false positives 2014-10-30 21:26:32 +01:00
PKEuS 6fdaf65cea Fixed createLinks2() when > is followed by ; (#6242) 2014-10-30 11:15:24 +01:00
Daniel Marjamäki 6088ba7951 Merge pull request #456 from simartin/ticket_6817_take2
Ticket #6187: Avoid infinite loop if eraseDeadCode does not remove anything (this time without memory corruption).
2014-10-23 09:43:02 +02:00
Daniel Marjamäki 4483c3e820 Fixed #6234 (FP : shift by too many bits is undefined on a QT container) 2014-10-23 06:52:19 +02:00
Simon Martin c6e2107d99 Ticket #6187: Avoid infinite loop if eraseDeadCode does not remove anything (this time without memory corruption). 2014-10-22 20:25:36 +02:00
Frank Zingsheim 71c5d4bd60 Ticket #6232 (cppOut of bounds array access)
--HG--
extra : rebase_source : 79ed3533a12a486ea3ed3f09f9bc55b1a4771161
2014-10-21 22:56:53 +02:00
Daniel Marjamäki a3efa1e180 Fixed #4776 (FP: Assignment of function parameter has no effect outside the function, with goto) 2014-10-21 16:21:33 +02:00
Robert Reif 42f709c09d Fixed #6229 (Move Windows builtin types __intXX to library) 2014-10-21 06:11:19 +02:00
Daniel Marjamäki d8b50e73df Fixed #6002 (Defect: False positive due to pointer address not being associated with variable in for loop) 2014-10-20 15:54:02 +02:00
Robert Reif d5908f03b7 Fixed #6226 (false negative: printf format check for user defined array type) 2014-10-20 06:33:36 +02:00
Robert Reif e2f72b4cb1 Fixed #6215 (Move Windows platform types into library) 2014-10-19 07:34:40 +02:00
PKEuS b724784f0b Removed obsolete comments 2014-10-18 11:18:07 +02:00
Daniel Marjamäki 0fd6586fcc Fixed #6219 (valueFlowForward: better multivariable analysis needed to avoid FP) 2014-10-17 06:50:33 +02:00
Frank Zingsheim 41a54fceba Fixed false positives about uninitialized member variables if variable has a default value (#5500) 2014-10-16 21:57:43 +02:00
Frank Zingsheim 3923618b8d Fixed #6222 (Missing varid for multiple braced initialized variables)
-> Fixed broken code in unit tests
2014-10-16 20:46:57 +02:00
PKEuS a99fd364ef Restored functionality to detect std::string(0) calls as null pointer dereferences (#6189) 2014-10-16 19:12:02 +02:00
Daniel Marjamäki 7107286be6 Fixed #5891 (AST: wrong ast generated for 'x = (int)(double(123)*i);') 2014-10-16 15:57:05 +02:00
PKEuS eefaddf980 Fixed bug in Tokenizer::simplifyReference() (#6133) 2014-10-16 11:43:42 +02:00
PKEuS 9a755714b5 Removed unused function from testsymboldatabase.cpp 2014-10-16 11:12:28 +02:00