1850 Commits

Author SHA1 Message Date
Robert Reif
8631ee65a3 Fixed #2474 (false positive: Member variable 'A::m_SemVar' is not initialised in the constructor.) 2011-01-18 07:34:11 +01:00
Robert Reif
c994508c3e Symbol database: Refactor the variables API. ticket: #2468 2011-01-18 07:32:06 +01:00
Daniel Marjamäki
965c1a94fd Fixed #2475 (False positive in structure initialisation: The scope of the variable bits can be reduced) 2011-01-17 20:51:15 +01:00
Daniel Marjamäki
b5020468f6 Fixed #2467 (false positive: possible nullptr dereference) 2011-01-17 19:23:00 +01:00
Daniel Marjamäki
065e2e277e Fixed #2473 (False positive: Memory leak when there is local struct) 2011-01-17 19:00:21 +01:00
Robert Reif
959e10cee5 Symbol database: renamed classes. ticket: #2468 2011-01-17 18:29:19 +01:00
Robert Reif
bf9528558e Symbol database: pulled out classes into global scope. ticket: #2468 2011-01-17 07:21:59 +01:00
Zachary Blair
481907ef14 Fixed #2457 (CheckOther::checkIncorrectLogicOperator: hang if variable id is 0) 2011-01-16 13:57:29 -08:00
Pete Johns
9c300813a4 Fixed gcc warning. 2011-01-17 08:52:26 +11:00
Pete Johns
7918c4b804 isVariableDeclaration() now detects template variables. 2011-01-17 08:36:53 +11:00
Pete Johns
38c37ad2d8 Moved array declaration detection into isVariableDeclaration() 2011-01-17 08:36:52 +11:00
Daniel Marjamäki
93d1313186 Refactoring: Check if type is class/struct through symbol database 2011-01-16 19:57:29 +01:00
Daniel Marjamäki
e6a1efa13b Fixed #2302 (Duplicate id 'unusedVariable') 2011-01-16 18:45:05 +01:00
Robert Reif
d341b42b0c Symbol database: increased constness. ticket: #2468 2011-01-16 18:13:54 +01:00
Daniel Marjamäki
657c22d23b cppcheck: output errorlist to stdout 2011-01-16 17:18:09 +01:00
Robert Reif
66be74a5af Symbol database: Refactorings. Move check-specific code to check. Ticket: #2468 2011-01-16 16:37:11 +01:00
Daniel Marjamäki
a97e28491f Fixed #2407 (False positive: unused private function) 2011-01-16 12:16:31 +01:00
Daniel Marjamäki
f72fd6960e Fixed #2449 (segfault in tokenize.cpp, incorrect parsing) 2011-01-16 11:54:28 +01:00
Raphael Geissert
da998fec68 Tokenizer: simplify restrict 2011-01-16 11:37:03 +01:00
Robert Reif
beb2db82a2 Fixed #980 (false negative: division by zero when using enum) 2011-01-16 11:24:58 +01:00
Robert Reif
0f6644e1ea Symbol database: Refactorings 2011-01-16 11:18:12 +01:00
Daniel Marjamäki
8ef47dc576 astyle formatting 2011-01-16 09:57:56 +01:00
Daniel Marjamäki
8fa26fbd28 Memory leaks: Optimised and refactored 2011-01-16 09:56:04 +01:00
Daniel Marjamäki
433ae8abf4 STL: Optimised checking 2011-01-15 22:38:05 +01:00
Daniel Marjamäki
bb2862bc97 fixed unit test 2011-01-15 21:04:20 +01:00
Daniel Marjamäki
94ebb24d3d Optimising: about 5% improvement with Visual Studio executable 2011-01-15 20:55:51 +01:00
Daniel Marjamäki
6edf35ebf5 Fixed #2463 (false positive: possible nullpointer dereference) 2011-01-15 12:09:36 +01:00
Daniel Marjamäki
97d0755750 Fixed #2454 (Tokenizer::simplifyKnownVariables: problem with float/double variables) 2011-01-15 08:48:42 +01:00
Daniel Marjamäki
5920dbb7e7 Fixed #2466 (Tokenizer: simplification of enum) 2011-01-15 08:21:06 +01:00
Robert Reif
8ecba0af90 Fixed #2464 (False positive: not initialised/not assigned Static variable in copy constructors.) 2011-01-15 08:04:50 +01:00
Robert Reif
79b9939610 Fixed #2465 (False positive: not initialised variable, but there is default constructor for it.) 2011-01-15 07:59:37 +01:00
Daniel Marjamäki
00b49a51da Fixed #2451 (False positive when incrementing map value via iterator) 2011-01-14 19:50:07 +01:00
Robert Reif
708a75e363 Fixed #2452 (syntax error when 'void f(typedef int x)' is used. causes segmentation fault.) 2011-01-14 07:41:22 +01:00
Kimmo Varis
dffe1a0acd Fix doxgen comment. 2011-01-13 23:25:17 +02:00
Kimmo Varis
4668e19060 Modify Cppcheck::addFile() only take one file as a parameter.
CLI and GUI already do the directory walking for us and we have list
of files to check. So we were duplicating this directory walking.
Practically doing check again for each file if it is a directory.
Which can take some time with large amount of files.
2011-01-13 23:18:04 +02:00
Daniel Marjamäki
b247d7d56e Fixed #2450 (False positive when iterator reused) 2011-01-13 20:57:44 +01:00
Daniel Marjamäki
36c1807228 Fixed #2458 (false positive: (warning) Redundant code: Found a statement that begins with numeric constant) 2011-01-13 20:12:57 +01:00
Zachary Blair
38be7056b0 Fixed #2434 (FP memleakOnRealloc) 2011-01-12 22:33:46 -08:00
Daniel Marjamäki
09f900ce79 Fixed #2440 (False negative: basic memory leak) 2011-01-11 20:14:15 +01:00
Kimmo Varis
846d3dae99 Accept include paths ending with backslash.
Convert include path to use internal path separators when parsing
command line. Convert back to native separators when using paths.

Ticket #2448 (Error in handling -I command line parameter)
2011-01-11 21:04:21 +02:00
Daniel Marjamäki
79e52a8c45 Fixed #2296 (Tokenizer: simplifyKnownVariable doesn't simplify pointer properly 'delete [] p;') 2011-01-11 19:34:35 +01:00
Daniel Marjamäki
9658e2299d Fixed #2443 (Possible null pointer dereference: xxx - otherwise it is redundant to check if xxx is null at line) 2011-01-10 19:57:26 +01:00
Daniel Marjamäki
2d92f1ff6a Fixed #2442 (False positive: Memory leak when function returns in 'if' instead of 'else if') 2011-01-10 19:35:06 +01:00
Reijo Tomperi
226b605774 Change year 2010 -> 2011 in license texts. 2011-01-09 21:33:36 +02:00
Daniel Marjamäki
2848abbf36 Fixed #1219 (improve check: null pointer not detected 'if (p) return; *p = 0;') 2011-01-09 20:16:16 +01:00
Daniel Marjamäki
79ef02812d Fixed #2211 (false negative: buffer access out of bounds for(int i=0; i !=6;i++)) 2011-01-09 18:51:28 +01:00
Daniel Marjamäki
88abb32ddf Fixed #2429 (Tokenizer: Wrong simplification of 'sizeof .1250E+04') 2011-01-09 10:09:54 +01:00
Daniel Marjamäki
d316f6005f Fixed #2409 (print a warning if provided path (commandline option -I [PATH]) does not exist) 2011-01-09 09:29:38 +01:00
Daniel Marjamäki
68beffca04 Fixed #2437 (false positive: possible null pointer dereference: tok2) 2011-01-08 17:16:52 +01:00
Daniel Marjamäki
67a1c6817b Error message: Replace " with ' around variable name 2011-01-08 14:35:18 +01:00