Robert Reif
3fcca23b53
Tokenizer: better handling of bitfields. Ticket: #1956
2010-08-22 09:41:22 +02:00
Robert Reif
77d634127c
Tokenizer: simplify DECLARE_DYNAMIC and DECLARE_DYNCREATE
2010-08-22 09:38:05 +02:00
Robert Reif
ac9078857e
Tokenizer: simplify bitfields. Ticket: #1956
2010-08-21 16:34:41 +02:00
Robert Reif
9c594684db
Tokenizer: handle DECLARE_DYNAMIC. Ticket: #1956
2010-08-21 07:55:14 +02:00
Robert Reif
7173e01926
Fixed #1965 (tokenizer::simplifyEnum add support for C++0x enums)
2010-08-21 07:44:56 +02:00
Daniel Marjamäki
741ce40e3d
Tokenizer::setVarId : fixed problem for class members
2010-08-20 19:28:10 +02:00
Robert Reif
f123e951ec
Fixed #1963 (typedef array incorrectly simplified)
2010-08-20 07:11:02 +02:00
Daniel Marjamäki
cfa7b4906e
Symbol database: bug fixes. Ticket: #1895
2010-08-18 22:42:04 +02:00
Daniel Marjamäki
0934035fcf
Fixed #1955 (cppcheck hangs with 100% cpu load)
2010-08-18 22:22:14 +02:00
Daniel Marjamäki
1fd773b245
Fixed #1944 (segfault in Tokenizer::simplifyLogicalOperator)
2010-08-17 20:06:20 +02:00
Daniel Marjamäki
aa00587fed
#1943 (segmentation fault of cppcheck (= default))
2010-08-17 19:50:21 +02:00
Daniel Marjamäki
64cdee62ef
Fixed #1942 (false positive: uninitialized variable in __asm__ statement)
2010-08-16 19:38:47 +02:00
Daniel Marjamäki
85acb005a2
Fixed #1941 (Internal error::Space Info::getVarList found variable with varid 0)
2010-08-16 18:51:25 +02:00
Daniel Marjamäki
fe482785aa
Variable Id: Fixed various bugs related to templates and bitfields. Ticket: #1928
2010-08-15 11:54:28 +02:00
Daniel Marjamäki
4949869f5f
removed unused variable 'dot'
2010-08-15 09:03:16 +02:00
Daniel Marjamäki
4ff9a1ac94
Fixed #1928 (missing varId for template class variable)
2010-08-14 20:50:49 +02:00
Daniel Marjamäki
cb72f21994
Optimisation in Tokenizer::tokenize
2010-08-11 17:29:33 +02:00
Daniel Marjamäki
0ea9e98680
Optimisation: Made inner loop in Tokenizer::setVarId faster
2010-08-10 19:06:45 +02:00
Daniel Marjamäki
a1f288d088
Tokenizer::setVarId : Fixed a problem when using static class members
2010-08-10 18:22:58 +02:00
Daniel Marjamäki
6a3befa720
Optimising: Tokenizer::setVarId when setting variable ids for struct/class members
2010-08-08 19:14:23 +02:00
Daniel Marjamäki
5a8181d425
Tokenizer: 'simplifyCalculations();' should have the same results as 'while (simplifyCalculations());'
2010-08-08 09:25:09 +02:00
Daniel Marjamäki
1555901077
Refactoring: Made Tokenizer::simplifyCalculations a little faster
2010-08-08 08:28:28 +02:00
Daniel Marjamäki
7911626aed
gcc: fixed some more -Wsign-conversion warnings
2010-08-06 22:43:06 +02:00
Daniel Marjamäki
12217461a2
gcc: fixed some more -Wsign-conversion warnings
2010-08-06 22:37:48 +02:00
Daniel Marjamäki
146465a6ad
gcc: Fixed some compiler warnings when using -Wsign-conversion. Ticket: #1487
2010-08-06 18:42:55 +02:00
Daniel Marjamäki
7fb44d1995
gcc: fixed some compiler warnings when using -Wsign-conversion
2010-08-06 18:32:31 +02:00
Daniel Marjamäki
6346e1aa90
Borland C++: Fixed compiler errors
2010-08-06 17:44:26 +02:00
Daniel Marjamäki
9edecd4a3f
Added ErrorLogger::reportProgress and removed ErrorLogger::ReportProgress. This will make it easier for GUI and other clients to display progress information.
2010-08-03 16:36:21 +02:00
Daniel Marjamäki
2e2baa23a6
Fixed #1909 (### Internal error in Cppcheck. Please report it)
2010-07-28 21:03:15 +02:00
Daniel Marjamäki
2fd2ab1712
Fixed a vs compiler warning. Ticket: #1901
2010-07-27 17:48:22 +02:00
Daniel Marjamäki
bb7484945a
Fixed #1887 (internal error in GLee)
2010-07-25 18:20:30 +02:00
Daniel Marjamäki
e358af9018
Refactoring: Report progress when checking takes a long time. Ticket: #1868
2010-07-25 18:19:37 +02:00
Daniel Marjamäki
0c65796984
Refactoring: Cleanup headers using checkheaders
2010-07-24 22:12:56 +02:00
Daniel Marjamäki
b8146271a2
Report progress when checking a file takes a long time. Ticket: #1868
2010-07-24 18:58:52 +02:00
Daniel Marjamäki
9b49202da8
Refactoring Tokenizer::syntaxError
2010-07-24 10:39:01 +02:00
Daniel Marjamäki
dd07d82c34
Refactoring MathLib: Report errors through the tokenizer. Ticket: #1839
2010-07-24 10:25:03 +02:00
Daniel Marjamäki
84e576de04
Refactoring: use MathLib add/sub instead of calculate
2010-07-24 10:13:45 +02:00
Daniel Marjamäki
8a0d989190
Refactoring: Don't throw exceptions in the tokenizer upon errors. Ticket: #1866
2010-07-23 14:02:29 +02:00
Daniel Marjamäki
e1612bc175
Fixed #1891 (Internal error when enum assigned to sizeof without brackets)
2010-07-22 22:21:12 +02:00
Daniel Marjamäki
f69109fbf6
Fixed #1828 (### Internal error in Cppcheck. Please report it.)
2010-07-22 19:57:48 +02:00
Daniel Marjamäki
3c376047ba
pulled changes from kimmov (filelocation-refactor)
2010-07-19 18:06:49 +02:00
Daniel Marjamäki
d4d0bc050a
Fixed #1865 (Tokenizer::simplifyRedundantParantheses: wrong handling of 'operator delete')
2010-07-19 12:06:20 +02:00
Daniel Marjamäki
e7690836fd
fixed the mistake I made when applying patch
2010-07-18 20:56:19 +02:00
Robert Reif
689de10abf
uninitialized class members: better handling of nested classes
2010-07-18 20:43:51 +02:00
Daniel Marjamäki
020a8a965c
use cppcheckError to report Tokenizer/Preprocessor error instead of std::cerr
2010-07-18 12:57:29 +02:00
Daniel Marjamäki
a4b887f21a
Fixed #1843 (Tokenizer::createTokens() calls std::exit(0))
2010-07-18 12:44:55 +02:00
Kimmo Varis
6db365e6f7
Improve path name handling in ErrorLogger.
...
This commit adds setfile() method to FileLocation class. The setfile
method converts in Windows path separators to internally used Unix
separators. And getfile() converts path separators back to Windows
separators. This fixes bugs that error reports had mixed path
separators in paths.
2010-07-17 01:27:40 +03:00
Kimmo Varis
ad0394939a
Refactor ErrorMessage constructor to take Severity::SeverityType.
...
This removes lots of unneeded casting as everybody now uses the
Severity::SeverityType.
2010-07-14 23:11:32 +03:00
Robert Reif
c572e6af87
Fixed #1846 (False positive with -s: Variable hides typedef with same name)
2010-07-13 08:08:12 +02:00
Daniel Marjamäki
61150498c4
Variable Id: fixed issue with function call. Ticket: #1848
2010-07-12 20:18:03 +02:00
Kimmo Varis
c9215e9e44
Change the "information" error to "debug" error.
...
There was one debugging error sent with "information" severity. That
confused the GUI that didn't know such severity. Change the severity
to "debug" so the meaning of the error is more clear.
2010-07-12 00:56:52 +03:00
Robert Reif
b0f1d5669b
Fixed #1829 (### Internal error in Cppcheck. Please report it.)
2010-07-07 07:40:11 +02:00
Robert Reif
1799e4a575
Fixed #1827 (### Internal error in Cppcheck. Please report it.)
2010-07-06 08:26:30 +02:00
Robert Reif
c949a29d1e
Fixed #1821 (simplifyTypedef: better typedef support)
2010-07-05 23:03:54 +02:00
Daniel Marjamäki
18a75edd20
Fixed #1823 (tokenize && wrong)
2010-07-05 22:41:02 +02:00
Daniel Marjamäki
b173d5f117
Fixed #1817 (False positive: Resource leak (casting))
2010-07-05 13:16:33 +02:00
Robert Reif
28c265b20c
Fixed #1821 (simplifyTypedef: better typedef support)
2010-07-02 15:22:29 +02:00
Robert Reif
b33fb48618
Fixed #1816 (Tokenizer: remove restrict keyword)
2010-06-30 08:10:39 +02:00
Daniel Marjamäki
46e2f1e64b
--author=Robert Reif <reif@earthlink.net>
...
Fixed #1814 (false positive: Variable hides typedef with same name)
2010-06-28 15:33:27 +02:00
Daniel Marjamäki
f82895c1f2
Fixed #1809 (false positive: uninitialized variable with nested if)
2010-06-26 17:15:44 +02:00
Robert Reif
539804369a
Fixed #1811 (false positive: Uninitialized variable)
2010-06-26 07:50:53 +02:00
Robert Reif
38f90dae09
Fixed #1813 (false negative: Member variable not assigned a value in operator=)
2010-06-25 07:52:12 +02:00
Robert Reif
fac9f66cc0
Fixed #1810 (False positive: Variable 'separator' is assigned a value that is never used)
2010-06-22 17:07:41 +02:00
Daniel Marjamäki
26e167fd5b
Refactoring: Removed redundant checks
2010-06-20 20:51:36 +02:00
Daniel Marjamäki
85bf4b2be6
Fixed #1795 (false positive: nullpointer dereference (needs to improve Tokenizer::simplifyKnownVariables))
2010-06-19 17:54:38 +02:00
Daniel Marjamäki
82b63dd736
Fixed #1633 (tokenizer: simplifyKnownVariable: improved handling of arithmetic)
2010-06-19 14:00:45 +02:00
Robert Reif
ec61c6fa26
Fixed #1801 (simplifyTypedef: duplicate typedefs not handled properly)
2010-06-18 07:16:05 +02:00
Robert Reif
f116e74f6e
Fixed #1801 (Segmentation fault while scanning Qt's qcups.cpp)
2010-06-17 06:59:01 +02:00
Robert Reif
ee7ad272d6
variable usage: fix false positives when __attribute__ is used. Ticket: #1792
2010-06-16 18:04:31 +02:00
Robert Reif
61e7e759f0
Fixed #1798 (structure templates)
2010-06-16 07:13:52 +02:00
Daniel Marjamäki
a42273da63
Fixed #887 (Tokenizer: Simplify variable value after loop)
2010-06-15 17:56:14 +02:00
Robert Reif
98ae660260
Fixed #1792 (false positive: Variable 'test' is assigned a value that is never used)
2010-06-14 15:46:57 +02:00
Daniel Marjamäki
cb7e9fbec1
Fixed #1776 (False Negative: Unitialized array)
2010-06-14 08:36:34 +02:00
Daniel Marjamäki
70bfa890a8
Fixed #1718 (Tokenizer add close braces to for loop at wrong place when if-else presents inside)
2010-06-13 08:00:46 +02:00
Robert Reif
18bb7488b9
Fixed #1787 (false negative: out of bounds in derived class)
2010-06-13 07:17:50 +02:00
Daniel Marjamäki
f3fbdc96e1
Fixed #1788 (Tokenizer: template destructor is lost)
2010-06-12 08:32:05 +02:00
Robert Reif
6b65b77acf
Fixed #1782 ((error) ### Internal error in Cppcheck. Please report it.)
2010-06-10 07:18:55 +02:00
Daniel Marjamäki
e64ce2e812
Fixed #1781 (false positive: uninitialized variable when using asm statement in macro)
2010-06-09 21:28:15 +02:00
Robert Reif
4c4844b722
Fixed #1723 (Variable assigned value which is never used but is thrown)
2010-06-03 07:05:57 +02:00
Daniel Marjamäki
08b6e6ee09
Fixed #1717 (False positive: Resource leak with while)
2010-05-30 13:15:15 +02:00
Daniel Marjamäki
83c62eca9c
Tokenizer: simplify loops that continue while errno is EINTR
2010-05-30 12:49:39 +02:00
Daniel Marjamäki
46b5e4e79a
Fixed #1716 (Wrong reporting of leak with close() in a while loop condition)
2010-05-29 22:20:10 +02:00
Daniel Marjamäki
d09e1df0d7
Fixed #1714 (Wrong precedence for shift operators when simplifying calculations?)
2010-05-29 20:27:08 +02:00
Robert Reif
1a25183e8f
Fixed #1671 (simplifyTypedef: support for more typedefs)
2010-05-29 07:52:06 +02:00
Robert Reif
3fb0260ef1
Fixed #1713 (remove Microsoft variants of inline)
2010-05-29 07:43:58 +02:00
Robert Reif
26a7d29760
Fixed #1671 (simplifyTypedef: support for more typedefs)
2010-05-28 06:55:54 +02:00
Robert Reif
dc34a1b3ff
Fixed #1711 (Wrong typedef name shown when struct declared with __attribute__)
2010-05-27 18:15:42 +02:00
Robert Reif
8881a0c361
Fixed #1671 (simplifyTypedef: support for more typedefs)
2010-05-27 07:00:33 +02:00
Robert Reif
019e1f9dfe
Fixed #1671 (simplifyTypedef: support for more typedefs)
2010-05-25 20:43:44 +02:00
Daniel Marjamäki
78255fdfc5
Tokenizer: Removed the Tokenizer::simplifyNamespaces. Ticket: #1700
2010-05-23 13:51:41 +02:00
Robert Reif
b20cf06b66
Fixed #1671 (simplifyTypedef: support for more typedefs)
2010-05-23 10:46:39 +02:00
Daniel Marjamäki
4633979ff7
fixed gcc compiler warnings (comparing float values)
2010-05-21 12:28:13 +02:00
Daniel Marjamäki
89ec49508d
Fixed gcc compiler warning
2010-05-21 12:13:05 +02:00
Daniel Marjamäki
8d2e4bc553
Tokenizer: give dead pointer a value
2010-05-21 08:26:53 +02:00
Daniel Marjamäki
f87eb774eb
Fixed #1646 (False positive: array access after return cannot have default loop value)
2010-05-18 19:55:23 +02:00
Robert Reif
41c43c1790
Fixed #1691 (False positive: Function parameter 'x' is passed by value. It could be passed by reference instead.)
2010-05-18 18:20:11 +02:00
Zachary Blair
1539c0b3d2
Fixed #1649 (add a warning for potential memory leaks when using realloc)
2010-05-17 22:46:48 -07:00
Robert Reif
0d7474042a
Fixed #1685 (segmentation fault of cppcheck)
2010-05-18 07:11:23 +02:00
Robert Reif
9dfbd3946a
Fixed #1673 (Tokenizer::simplifyTypedef causes segfault for boost library)
2010-05-17 19:58:27 +02:00
Daniel Marjamäki
453adb4ea4
Tokenizer: it is bad to do: 'tok->previous()->deleteThis()'
2010-05-17 19:50:36 +02:00
Daniel Marjamäki
56d176e1ce
Fixed #1684 (false positive: buffer access out of bounds when using extern variable declaration)
2010-05-16 20:21:22 +02:00
Erik Lax
19aaa32a99
Fixed #1688 (Tokenizer::simplifyKnownVariables and pointer assignments)
2010-05-16 19:38:44 +02:00
Daniel Marjamki
8b1ffefd74
Fixed #1682 (Internal error)
2010-05-14 18:40:15 +02:00
Robert Reif
f8cceface5
Fixed #1677 (False positive: (style) Variable 'xxx' is assigned a value that is never used)
2010-05-13 13:59:41 +02:00
Robert Reif
963108d957
Fixed #1671 (simplifyTypedef: support for more typedefs)
2010-05-11 21:41:33 +02:00
Robert Reif
a390f3c8f4
Better handling of function pointer typedef
2010-05-10 17:50:40 +02:00
Robert Reif
ac7515cdcc
Fixed #1666 (simplifyTypedef: add support for typedefs of functions)
2010-05-10 07:12:06 +02:00
Daniel Marjamäki
d19dd2c61d
Fixed #1654 (False positive: Memory leak with: ( delete ( p ) , ( p ) = 0 );)
2010-05-07 18:37:50 +02:00
Daniel Marjamäki
c8c5f95721
Fixed #1651 (Tokenizer::setVarId wrong handling of return statement)
2010-05-06 18:40:52 +02:00
Daniel Marjamäki
af4c4cef34
Fixed #1646 (False positive: array access after return cannot have default loop value)
2010-05-05 18:29:56 +02:00
Daniel Marjamäki
612be2557b
Fixed #1646 (False positive: array access after return cannot have default loop value)
2010-05-04 20:02:47 +02:00
Daniel Marjamäki
804b2a0952
Fixed #1642 (Tokenizer::simplifyKnownVariables: simplify after loop)
2010-05-02 14:41:21 +02:00
Slava Semushin
f50d182750
Fixed #1574 (chain assignments could be simplified)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1574
2010-05-01 15:28:35 +07:00
Daniel Marjamäki
080374dc04
Fixed #1638 (Tokenizer::simplifyKnownVariables: removing variable declaration)
2010-05-01 10:09:53 +02:00
Eric Sesterhenn
b261e5df25
Fixed #1634 (Null character not correctly tokenized)
2010-04-29 18:30:23 +02:00
Robert Reif
c79b9a8aac
Fixed #1631 (Tokenizer: remove register keyword)
2010-04-29 07:17:38 +02:00
Daniel Marjamäki
6bb93b5eb7
Fixed #943 (Tokenizer: improve handling of pointer aliasing)
2010-04-25 15:12:47 +02:00
Daniel Marjamäki
8ccd95a643
Fixed #836 (buffer overrun: memmove)
2010-04-24 21:48:58 +02:00
Robert Reif
99a7755218
tokenizer improvements: remove calling convention ( #1619 )
2010-04-24 09:40:05 +02:00
Zachary Blair
5835b2665b
Fixed #1169 (improve check: divsion by zero not detected when using the shift (>>) operator)
2010-04-23 22:59:53 -07:00
Robert Reif
f4ce5a37d7
Fixed #1615 (False positive - C-style pointer casting)
2010-04-22 20:08:29 +02:00
Robert Reif
90541386da
Fixed #1619 (tokenizer: remove calling convention)
2010-04-21 21:08:47 +02:00
Robert Reif
bee4608b27
Fixed #1613 (False -s positive: Template instantiation hides typedef with same name)
2010-04-18 09:13:55 +02:00
Robert Reif
d90f59051c
Fixed #1612 (false positive: The function can be const)
2010-04-18 07:53:39 +02:00
Daniel Marjamäki
c718a7c595
astyle: Update to astyle 1.24
2010-04-15 20:08:51 +02:00
Daniel Marjamäki
3fa2137ee3
Fixed #1596 ('Index out of bounds' false positive)
2010-04-15 19:09:19 +02:00
Robert Reif
176795ef95
Another fix for #1601 (change simplifyInitVar to split declaration from initialization)
2010-04-15 18:42:11 +02:00
Robert Reif
d2bb4964d0
Fixed #1588 (typedef struct incorrectly simplified)
2010-04-14 19:06:51 +02:00
Robert Reif
3bbb2e1d7f
Fixed #1601 (change simplifyInitVar to split declaration from initialization)
2010-04-14 19:04:16 +02:00
Reijo Tomperi
0912836c25
Fix: sizeof(char*) was not simplified correctly
2010-04-13 23:17:27 +03:00
Reijo Tomperi
4a33b226e6
Fix #1599 (false positive on if( (f = fopen("foo", "r")) == ((FILE*)NULL) ))
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1599
2010-04-13 22:57:52 +03:00
Reijo Tomperi
35d2a27b9c
Update copyright year in all source files
2010-04-13 22:23:17 +03:00
Daniel Marjamäki
a7903c3385
dos2unix
2010-04-13 19:25:08 +02:00
firewave
8966888a92
Fixed some VS2008 warnings
2010-04-13 11:31:27 +02:00
Daniel Marjamäki
38a3fe37f9
Revert "Optimization: Made Tokenizer::setVarId a bit faster by temporarily assigning 'string id'. This means less string comparisons are needed."
...
This reverts commit 4b8080e425
.
2010-04-12 21:17:31 +02:00
Robert Reif
67fafd4028
Fixed #1588 (typedef struct incorrectly simplified)
2010-04-12 19:05:31 +02:00
Daniel Marjamäki
4b8080e425
Optimization: Made Tokenizer::setVarId a bit faster by temporarily assigning 'string id'. This means less string comparisons are needed.
2010-04-11 21:37:35 +02:00
Reijo Tomperi
d1f22d50e6
Fix last of the -Wshadow warnings.
2010-04-11 14:49:50 +03:00
Zachary Blair
3152816619
Fixed #779 (Tokenizer: delete register keyword everywhere)
2010-04-10 09:58:09 +02:00
Robert Reif
bc0a318b6d
Fixed #1580 (unnamed anonymous struct can segfault)
2010-04-08 17:40:23 +02:00
Reijo Tomperi
6db663f6de
Fix #1322 (Add cppcheckError and unusedFunction to --errorlist, give out internal errors in xml)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1322
2010-04-04 23:55:28 +03:00
Daniel Marjamäki
849be383e6
Tokenizer: tokenize 1E-2 into a single token
2010-04-04 08:01:05 +02:00
Daniel Marjamäki
a4144b9d18
Refactoring: Moved copy/paste code in Tokenizer
2010-04-03 09:54:10 +02:00
Daniel Marjamäki
ff38bbf468
Cleanup: The Tokenizer doesn't need to handle UTF in code nor multiline string. That is handled in the Preprocessor.
2010-04-02 20:48:32 +02:00
Daniel Marjamäki
c6bbc9d739
Fixed #1565 (False positive: Uninitialized variable 'B::j'. There are 2 classes with the name 'B')
2010-04-02 19:29:54 +02:00
Daniel Marjamäki
0cad22314e
Reverted 'astyle fix'. Those changes are not in sync with my astyle configuration/setup.
2010-04-02 07:30:58 +02:00
Martin Ettl
193aa7d1d3
astyle fix
2010-04-02 02:21:53 +02:00
Daniel Marjamäki
a68d8dbc77
Fixed #1549 (false positive: uninitialized variable)
2010-03-31 20:20:51 +02:00
Robert Reif
ef57d01f7a
Fixed #1492 (false negatives: array index out of bounds)
2010-03-31 17:14:49 +02:00
Robert Reif
62d2845014
Fixed #1492 (false negatives: array index out of bounds)
2010-03-28 15:56:13 +02:00
Reijo Tomperi
86fabd03b3
Fix #1532 (hang due to commit 772aa95c8a
)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1532
2010-03-27 21:52:31 +02:00
Robert Reif
c50469dba6
Fixed #1523 (false negative:: buffer access out of bounds when using shift operator)
2010-03-27 07:21:08 +01:00
Robert Reif
45865f54a8
Fixed #1525 (false negative: the function can be declared as const (member declared as mutable))
2010-03-26 19:06:00 +01:00
Daniel Marjamäki
80edb4d8f4
Tokenizer: Simplify 'false ==' to '!'
2010-03-24 19:55:02 +01:00
Daniel Marjamäki
5b1b845750
Fixed #1504 (False positive: Cppcheck incorrectly reports that extern variable is not initialized)
2010-03-20 08:03:18 +01:00
Daniel Marjamäki
f687e85be5
Fixed #1498 (false positive: The function 'V<unsigned>::vSet' can be const)
2010-03-19 19:34:26 +01:00
Robert Reif
0fb680d887
Tokenizer: remove unnamed anonymous structures and unions ( #1493 )
2010-03-19 19:04:56 +01:00
Robert Reif
9c2248254e
Here is a patch that adds support for derived structs and fixes a bug that missed some nested structs. ( #1493 )
2010-03-19 16:17:25 +01:00
Daniel Marjamäki
c7bd437d7d
astyle formatting
2010-03-19 16:12:51 +01:00
Daniel Marjamäki
95d22de690
Fixed #1508 (false positive : uninitialized variable)
2010-03-18 19:23:38 +01:00
Robert Reif
5ea7e32bf9
Partial fix for #1493 (false positives: function can be const and struct or union member is never used)
2010-03-18 18:14:52 +01:00
Daniel Marjamäki
e911d1f1df
doxygen updates
2010-03-17 22:16:18 +01:00
Robert Reif
b3856cbc5e
Fixed #1506 (typedef name hiding check combined with forward declaration leeds to false positive)
2010-03-17 17:31:08 +01:00
Daniel Marjamäki
12c45a1aba
Fixed #1476 (false positive: Uninitialized variable)
2010-03-16 19:53:09 +01:00
Daniel Marjamäki
382e41d92a
Fixed #1494 (Improve Tokenizer::simplifyKnownVariables to handle for loops better)
2010-03-14 09:57:34 +01:00
Daniel Marjamäki
772aa95c8a
Fixed #1477 (false positive: Uninitialized variable when pointer given to struct)
2010-03-13 11:52:48 +01:00
Kimmo Varis
d1bbcf1734
Implement Win32 FileLister as separate class.
...
Improve the system used to have separate versions of code of FileLister for
Win32 and Linux. New idea is to have Base FileLister class implementing
common code and then derived classes for Win32 and Linux specific code.
FileLister is not anymore a static class. Instead we use singleton of
derived class.
2010-03-11 21:58:59 +02:00
Daniel Marjamäki
587081cab5
Fixed #1488 (Invalid warning about shadowed variable)
2010-03-10 16:47:39 +01:00
Daniel Marjamäki
770d2ff835
Simplify enum: Fixed segmentation fault if code ends with enum type id
2010-03-07 13:01:56 +01:00
Daniel Marjamäki
fa493b7fd1
Fixed #1474 (segmentation fault of cppcheck)
2010-03-07 12:50:45 +01:00
Reijo Tomperi
b88126a669
Fix #1469 (False positive: Resource leak when fclose() is inside while)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1469
2010-03-06 16:28:52 +02:00
Daniel Marjamäki
fe30c1ca9d
Fixed #1432 (false positive: uninitialized variable)
2010-03-06 13:48:43 +01:00
Reijo Tomperi
237fdbc653
Fix #1454 (False positive: arrayindexoutofbounds, static member sharing local name)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1454
2010-03-06 14:35:04 +02:00
Daniel Marjamäki
d643bbe864
simplify templates: show debug message when bailout out
2010-03-04 18:20:08 +01:00
Daniel Marjamäki
b55a7f2815
SimplifyTemplates: some simple refactoring so template name is properly seen. If it's not properly handled then bailout. Related with #1464
2010-03-04 17:34:14 +01:00
Reijo Tomperi
d881fd7a31
Partial fix #1464 (takes too long (days) to process some files)
...
Fix template functions that return "&T".
http://sourceforge.net/apps/trac/cppcheck/ticket/1464
2010-03-03 23:02:32 +02:00
Reijo Tomperi
75c0ed7e6e
Add simple debug print to make it possible to detect cases where template simplification goes wrong.
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1464
2010-03-02 23:55:05 +02:00
Daniel Marjamäki
248b6aa159
cleanup: removed unused variables
2010-02-28 07:38:07 +01:00
Daniel Marjamäki
6ca4b008d0
null pointer: Fixed better error message for 'possible null pointer' + removed redundant check in our Tokenizer.
2010-02-28 07:26:50 +01:00
Daniel Marjamäki
50210857a6
Fixed #1439 (false positive: memory leak when using realloc)
2010-02-27 19:41:14 +01:00
Daniel Marjamäki
c9ff53fbed
Refactoring error messages
2010-02-27 17:06:33 +01:00
Daniel Marjamäki
a8ee4a03f0
Fixed #1456 (PATCH: Variable hides typedef with same name false positive)
2010-02-27 07:27:51 +01:00
Daniel Marjamäki
ce0131a1e6
Fixed #1397 (false positive: Memory leak in while loop)
2010-02-26 22:14:56 +01:00
Robert Reif
54bf67e766
Fixed #1456 (PATCH: Variable hides typedef with same name false positive)
2010-02-26 21:43:00 +01:00
Robert Reif
f4d600e93b
Fixed #1457 (PATCH: Variable hides enumerator with same name false negative)
2010-02-26 21:40:57 +01:00
Daniel Marjamäki
377d3091a9
Fixed #1452 (Simplify goto better)
2010-02-25 20:03:39 +01:00
Robert Reif
f9d444ed52
Fixed #1445 (segfault in Tokenizer::simplifyRedundantParanthesis())
2010-02-25 07:24:32 +01:00
Robert Reif
7d8adfb4df
Fixed #1449 (segmentation fault of cppcheck)
2010-02-24 17:50:02 +01:00
Robert Reif
d9df3d5c6e
Fixed #1434 (### Internal error in Cppcheck. Please report it.)
2010-02-23 22:12:55 +01:00
Daniel Marjamäki
459a3bac50
Fixed #1396 (false positive: Resource leak)
2010-02-21 09:47:41 +01:00
Daniel Marjamäki
7a72932078
Tokenizer: simple simplification of array sizes
2010-02-20 18:13:09 +01:00
Daniel Marjamäki
e4cc8cf1a0
Fixed #1395 (false positive: Possible null pointer dereference)
2010-02-20 15:50:44 +01:00
Daniel Marjamäki
ccef1d6eb5
Fixed #1424 (false positive: unintialized variable)
2010-02-20 13:24:50 +01:00
Daniel Marjamäki
084b21494a
Fixed #1422 (false positive: uninitialized variable)
2010-02-20 11:43:53 +01:00
Robert Reif
24628013f1
Fixed #1427 (new check: check for typedef name hiding)
2010-02-20 09:07:29 +01:00
Daniel Marjamäki
57f63f65c2
Borland C++: Fixed compiler errors (operands must be same type)
2010-02-20 08:53:33 +01:00
Robert Reif
5c6ec0364d
Fixed #1411 (### Internal error in Cppcheck. Please report it.)
2010-02-18 07:24:24 +01:00
Robert Reif
deb71fc566
Fixed #1405 (false positive: operator = should return reference to itself)
2010-02-17 22:42:08 +01:00
Robert Reif
f15c408f13
Fixed #1388 (enum token/template parameter confusion - False positive)
2010-02-16 07:33:23 +01:00
Daniel Marjamäki
9394816fcf
Refactoring: Use std::string instead of const char *
2010-02-14 19:58:17 +01:00
Reijo Tomperi
b52fa9451f
Fix #1385 (False positive: unsigned division)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1385
This also fixes a bug in setVarId(). "unsigned int a" didn't get varid,
untill later when unsigned was simplified away.
2010-02-12 22:24:06 +02:00
Reijo Tomperi
45abd2d7fc
Fix #1366 (void Tokenizer::simplifyTemplates() --> Abort)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1366
2010-02-09 00:16:12 +02:00
Daniel Marjamäki
8853f304af
Fixed #1364 (False positive: (error) Possible null pointer dereference)
2010-02-08 18:25:08 +01:00
Daniel Marjamäki
cd5b95849d
Fixed #1361 (### Internal error in Cppcheck. Please report it)
2010-02-07 15:00:19 +01:00
Daniel Marjamäki
fb09b2fd37
Fixed #1356 (Double-False positive: uninitialized variable)
2010-02-07 13:34:39 +01:00
Daniel Marjamäki
1b0c81a24b
Tokenizer: Fixed bug in setVarId. functions should never have a variable id
2010-02-07 13:04:33 +01:00
Daniel Marjamäki
ed8f3bc806
Fixed #1362 (Internal error when using ?-operator and nested {})
2010-02-07 09:14:59 +01:00
Daniel Marjamäki
93bb1c0174
astyle formatting
2010-02-06 23:51:29 +01:00
Daniel Marjamäki
0a31e5e3ee
Fixed #1352 (false positive: uninitialized variable)
2010-02-06 16:51:32 +01:00
Robert Reif
b78845174d
Fixed #1355 (Fixed enum bug when expression contain comma)
2010-02-06 09:49:56 +01:00
Robert Reif
6cbfc5f894
Fixed #1351 (add expression support to simplifyEnum)
2010-02-05 07:37:17 +01:00
Daniel Marjamäki
0ba665d77f
Fixed #1337 (Division by zero with __alignof__())
2010-02-03 21:23:44 +01:00
Daniel Marjamäki
d3b5889f88
Fixed #1345 (Not initialised variables warning missing in classes with dllexport)
2010-02-03 20:01:56 +01:00
Robert Reif
f2eac901c0
Fixed #1343 (simplifyTypedef doesn't support deeply nested classes)
2010-02-03 07:58:36 +01:00
Daniel Marjamäki
4ec94116f5
Fixed #1341 (false positive 'uninitialized variable' when using Exception specifications)
2010-02-02 19:56:41 +01:00
Robert Reif
b704fc7bc7
Fixed #1339 (add nested struct support to simplifyEnum and simplifyTypedef)
2010-02-01 19:59:24 +01:00
Robert Reif
64afcc8179
Fixed #1338 (simplify typedefs with global and nested namespace)
2010-01-31 21:46:18 +01:00
Daniel Marjamäki
1375a60e3f
Fixed #1004 (improve check: Unintialized variable not detected when using a reference (&))
2010-01-31 16:29:12 +01:00
Daniel Marjamäki
1a59e1bc68
Tokenizer: remove redundant assignments and variables
2010-01-31 09:52:19 +01:00
Daniel Marjamäki
e15a16eb15
Tokenizer: Remove redundant assignments and variables
2010-01-31 09:33:57 +01:00
Daniel Marjamäki
e1efad0c27
Tokenizer: remove the keyword 'inline'
2010-01-31 08:11:29 +01:00
Robert Reif
d17d199415
Tokenizer: fix for multiple array definitions for a single typedef
2010-01-31 07:16:19 +01:00
Robert Reif
630d9ba552
Fixed #1326 (remove simplified enum definitions)
2010-01-31 07:13:09 +01:00
Robert Reif
7cbdb9f8a1
Fixed #1331 (simplify typedef of complex arrays)
2010-01-30 19:41:22 +01:00
Daniel Marjamäki
8716c771a4
Tokenizer: improved the simplifyInitVar
2010-01-30 14:25:11 +01:00
Daniel Marjamäki
3b08712930
Fixed #1005 (improve check: nullpointer dereference not found when it is initialized with NULL-cast)
2010-01-30 09:33:16 +01:00
Robert Reif
882e2225e0
Fixed 1329 (simplify typedef of function pointer returning template)
2010-01-30 08:00:11 +01:00
Daniel Marjamäki
f9d5fb3191
Fixed #1327 (False positive: Redundant code: Found a statement that begins with numeric constant)
2010-01-29 22:28:49 +01:00
Reijo Tomperi
1d5ba4e320
Improved updateClassList(), but not yet took it into use.
...
findClassFunction is now non-static.
updateClassList usage is currently commented out as it doesn't handle class inside a function
2010-01-29 23:22:18 +02:00
Daniel Marjamäki
53f514fc5c
Tokenizer: Fixed const simplification
2010-01-29 19:34:43 +01:00
Robert Reif
19bb2940cc
Fixed #1325 (Segmentation fault in simplifyTypedef due to bad preprocessing)
2010-01-29 16:00:48 +01:00
Robert Reif
fc54ed1eef
Fixed #1326 (remove simplified enum definitions)
2010-01-29 15:57:26 +01:00
Robert Reif
45b6b9e5a1
Fixed #1316 (### Internal error in Cppcheck. Please report it.)
2010-01-27 19:03:24 +01:00
Robert Reif
8be8c266ac
Fixed #1313 (unnamed enums not simplified properly)
2010-01-25 07:45:16 +01:00
Robert Reif
989e8393e4
Fixed #1307 (Internal error with typedef in parameter list)
2010-01-24 22:40:35 +01:00
Daniel Marjamäki
65881b9346
Fixed #1238 (False Negative : memory leak with template class)
2010-01-24 20:04:09 +01:00
Daniel Marjamäki
6d9740adea
Tokenizer: Fixed Tokenizer::simplifyKnownVariable bug when the variable is re-assigned in a loop
2010-01-24 19:27:39 +01:00
Reijo Tomperi
24052c16b4
Fix some style errors found from our own code.
2010-01-23 23:44:08 +02:00
Reijo Tomperi
7817d5b142
Fix #1279 (Change error message: Invalid number of character ({). Can't process file.)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1279
2010-01-23 23:18:11 +02:00
Daniel Marjamäki
8a9eba980b
Function pointers: re-enabled the simplifyFunctionPointers
2010-01-23 07:43:12 +01:00
Robert Reif
13ca2510cc
Fixed #1298 ((error) ### Internal error in Cppcheck. Please report it. (typedef in fun proto))
2010-01-22 20:26:07 +01:00
Daniel Marjamäki
1552c0f7f2
Fixed #1276 (False Uninitialized variable when using goto)
2010-01-22 20:20:43 +01:00
Robert Reif
9f853cb164
Fixed #1297 (typedef causes internal error in vlc/modules/access/imem.c)
2010-01-22 17:27:40 +01:00
Daniel Marjamäki
d4b13eee9f
Fixed #1290 (1.40: Internal error)
2010-01-21 20:05:32 +01:00
Robert Reif
9f0b9551cf
This patch simplifies the function pointer return type code and allows more complex return types.
2010-01-21 18:01:09 +01:00
Robert Reif
e9e64033e7
Improved typedef simplification of function pointers
2010-01-21 07:51:08 +01:00
Daniel Marjamäki
3447030564
Merge branch 'master' of git@github.com:danmar/cppcheck
2010-01-20 21:19:32 +01:00
Daniel Marjamäki
96359b14ff
Simplify function pointers
2010-01-20 21:19:06 +01:00
Robert Reif
e163f878ab
Handle/simplify function pointer typedefs
2010-01-20 21:16:40 +01:00
Reijo Tomperi
b83d257852
Fix #1296 (false positive: index out of bounds)
...
http://sourceforge.net/apps/trac/cppcheck/ticket/1296
2010-01-20 21:26:54 +02:00