Commit Graph

76 Commits

Author SHA1 Message Date
Reijo Tomperi d4a97eb2b4 Fix #419 (missleading buffer overrun)
http://sourceforge.net/apps/trac/cppcheck/ticket/419
2009-10-01 10:59:27 +03:00
Reijo Tomperi ec44f8f6c7 Fix #744 (False positive: (possible error) Array index out of bounds)
http://sourceforge.net/apps/trac/cppcheck/ticket/744
2009-09-30 15:51:33 +03:00
Daniel Marjamäki 12b29e35ad Ashim Kapoor: deal with backspace better (#694) 2009-09-29 17:02:19 +02:00
Slava Semushin 342e71803f src/checkbufferoverrun.cpp: fixed regression.
test suite was broken after my
e8c83613e4 commit.
2009-09-27 23:03:11 +07:00
Slava Semushin e8c83613e4 Fixed #740 (False positive, buffer overrun with --all)
Regression since 07f41f4563 commit.

http://sourceforge.net/apps/trac/cppcheck/ticket/740
2009-09-27 22:50:59 +07:00
Slava Semushin f62e5f1672 src/checkbufferoverrun.cpp: removed useless semicolon.
No functional change.
2009-09-27 22:14:58 +07:00
Slava Semushin 661ce78b69 Fixed #738 (False Buffer overrun with -a when i is increased by more than 1 inside loop body)
http://sourceforge.net/apps/trac/cppcheck/ticket/738
2009-09-27 22:14:51 +07:00
Reijo Tomperi fdde2182b9 Fix GPL comments in all files. ">." was missing from the end. 2009-09-27 18:08:31 +03:00
Slava Semushin 07f41f4563 Fixed #714 (False Buffer overrun with -a when i is increased by more than 1 in a loop)
http://sourceforge.net/apps/trac/cppcheck/ticket/714
2009-09-27 21:12:46 +07:00
Slava Semushin acdbb20c99 Detect buffer overruns when ?: use as sprintf() argument. 2009-09-27 00:40:58 +07:00
Slava Semushin 19ed8e9311 Fixed #729 (False positive: Buffer overrun when ? is used to select parameter)
http://sourceforge.net/apps/trac/cppcheck/ticket/729
2009-09-27 00:06:54 +07:00
Slava Semushin 6d56ab9df6 CheckBufferOverrun::count(): commented out debug message.
Added in 3da779725d commit.
2009-09-26 21:59:16 +07:00
Daniel Marjamäki 3da779725d Ashim Kapoor: handle %i,%f,%d,%x,%X better (#694) 2009-09-26 16:19:18 +02:00
Reijo Tomperi 6a63742dde Fix #730 (False positive, buffer overrun with strncpy)
http://sourceforge.net/apps/trac/cppcheck/ticket/730
2009-09-25 23:32:18 +03:00
Daniel Marjamäki fe3c8cab9f Ashim Kapoor: Added function that returns minimum size of format strings (#694) 2009-09-25 18:23:44 +02:00
Reijo Tomperi 2dc1fe5dc1 astyle fix 2009-09-20 22:42:43 +03:00
Slava Semushin 5dee65048f Fixed #690 (False positive: (possible error) Buffer overrun)
http://sourceforge.net/apps/trac/cppcheck/ticket/690
2009-09-20 17:54:19 +07:00
Daniel Marjamäki c0ca375ef7 Fixed #478 (Warnings in Visual Studio build with -W4) 2009-09-13 09:03:48 +02:00
Slava Semushin c50f7787f9 Fixed #569 (Buffer overrun not detected when strcat() called few times)
http://sourceforge.net/apps/trac/cppcheck/ticket/569
2009-08-30 18:44:23 +07:00
Slava Semushin 1a982a2a19 CheckBufferOverrun::checkScope(): use Token::getStrLength().
No functional change.
2009-08-30 18:21:42 +07:00
Slava Semushin 7c86a10a9d Fixed #617 (False positive "buffer overrun" when sprintf() doesn't have optional parameters)
http://sourceforge.net/apps/trac/cppcheck/ticket/617
2009-08-27 00:21:32 +07:00
Daniel Marjamäki 2cdb0abb82 Refactoring: Use the Token::link instead of loop 2009-08-17 22:23:37 +02:00
danmar 3de825c290 Borland C++ Builder: Fixed compilation and testrunner problems 2009-08-13 22:13:52 +02:00
Slava Semushin eebb1671a5 checkbufferoverrun.cpp: get rid of Match() usage with varid 0. 2009-08-09 01:09:45 +07:00
Slava Semushin 0f96299d87 Fixed ticket #570 (Buffer overrun not detected when sprintf() format string greater then buffer size)
http://sourceforge.net/apps/trac/cppcheck/ticket/570
2009-08-08 21:52:35 +07:00
Slava Semushin 92d4c086ce Fixed ticket #571 (Buffer overrun for sprintf() not detected after first ')' symbol)
http://sourceforge.net/apps/trac/cppcheck/ticket/571
2009-08-08 21:03:10 +07:00
Reijo Tomperi 80953633ee Fix ticket #563 (set variable id for **p)
http://sourceforge.net/apps/trac/cppcheck/ticket/563
2009-08-06 23:11:29 +03:00
Daniel Marjamäki 5087dc6b46 Bail out if variable id is 0. This should be reverted when #563 has been fixed 2009-08-06 21:48:22 +02:00
Daniel Marjamäki cb57bd6678 Listing error messages in XML format 2009-08-04 21:36:55 +02:00
Slava Semushin be82d09003 src/checkbufferoverrun.cpp: fixed regression. 2009-08-02 20:34:28 +07:00
Slava Semushin 13532cbff7 src/checkbufferoverrun.cpp: don't call Token::Match() for variables with varId 0. 2009-08-02 20:01:59 +07:00
Slava Semushin 822fb93cda Improved "index out of bounds" check.
Corrected 342acaaaf2 commit.
2009-08-02 19:29:45 +07:00
Slava Semushin 342acaaaf2 Fixed #547 (index out of bounds not detected when addition used as array index)
http://sourceforge.net/apps/trac/cppcheck/ticket/547
2009-08-02 14:59:02 +07:00
Slava Semushin 6c022798ea Fixed ticket #499 (buffer overflow not detected when using macros)
sprintf() buffer overrun detection works wrong due to typo (since time
when it was added in commit a604f56f19).

Also reports buffer overrun when sprintf() writes bytes equal to
buffer size -- in this case off-by-one error appears.

http://sourceforge.net/apps/trac/cppcheck/ticket/499
2009-07-26 19:29:46 +07:00
Daniel Marjamäki 18f9e05f5a refactoring: Renamed checking classes 2009-07-13 16:00:15 +02:00
Daniel Marjamäki 7d35447d80 refactoring: renamed the severity "all" to "possible error" 2009-07-13 10:16:31 +02:00
Daniel Marjamäki 36896e1ca0 better description for the message with id strncatUsage 2009-07-11 12:16:38 +02:00
Reijo Tomperi 8b0e481d46 Refactoring: Rename member functions to follow naming guidelines. 2009-07-05 23:16:43 +03:00
Reijo Tomperi 751a31ed91 Fix ticket #445 (simple to avoid false positive for buffer overflow)
http://sourceforge.net/apps/trac/cppcheck/ticket/445
Simple bailout in case "if" is found inside the for-loop.
2009-06-30 00:42:46 +03:00
Daniel Marjamäki b4c637c58b Fixed #350 (False positive: Array index out of bounds) 2009-06-02 18:56:53 +02:00
Daniel Marjamäki 6ef87e8eab Fixed #339 (Buffer overrun not detected with pointer arrays)
http://apps.sourceforge.net/trac/cppcheck/ticket/339
2009-06-01 19:21:08 +02:00
Reijo Tomperi 58eda6e978 Fix ticket #325 (Replace developer names in source files with AUTHORS file)
http://apps.sourceforge.net/trac/cppcheck/ticket/325
2009-05-30 08:48:12 +03:00
Reijo Tomperi cb209bbd41 Fix #279 (Refactoring: replace and remove Token::aaaa , Token::aaaa0 and Token::aaaa1)
http://apps.sourceforge.net/trac/cppcheck/ticket/279
2009-05-03 21:10:59 +03:00
Daniel Marjamäki 6f4c5ab71c refactoring: Replaced 'aaaa' 2009-05-01 22:41:55 +02:00
Reijo Tomperi 11858129d0 Fix ticket #243 (boundary checking)
http://apps.sourceforge.net/trac/cppcheck/ticket/243
2009-04-04 21:05:48 +03:00
Daniel Marjamäki b9f4a773b8 Buffer overrun: Added check to detect when size argument to memset is a char constant (#213) 2009-03-25 07:25:10 +01:00
Daniel Marjamäki 6580e0eb21 fixed snprintf false positive (#210) 2009-03-24 18:43:39 +01:00
Daniel Marjamäki 6fc66d3e2c refactoring error messages 2009-03-21 21:33:27 +01:00
Daniel Marjamäki 9f1c3cc535 refactoring the rest of the classes 2009-03-20 18:16:21 +01:00
Daniel Marjamäki 21dff96e7b refactoring checkbufferoverrun 2009-03-20 17:35:53 +01:00