Dmitry-Me
eaa12db761
scanf with %zd expects ssize_t, not ptrdiff_t
2017-10-24 22:01:23 +03:00
Dmitry-Me
709ee6e278
Revert "Initial test coverage for %zd used with scanf"
...
This reverts commit a260b5157a
.
2017-10-24 00:20:04 +03:00
Dmitry-Me
a748ced9da
Improve test coverage for %zx, %zu used with printf
2017-10-23 23:44:22 +03:00
Dmitry-Me
a260b5157a
Initial test coverage for %zd used with scanf
2017-10-23 23:42:29 +03:00
Dmitry-Me
481ab0f930
Tests for passing non-pointers as scanf read targets
2017-10-23 23:35:32 +03:00
Daniel Marjamäki
28cfee2d4f
Fixed #8250 (New check: Pointer calculation result cant be NULL unless there is overflow)
2017-10-22 14:32:54 +02:00
Daniel Marjamäki
4cb3548e2b
unsafeClassDivZero: change severity to style
2017-10-21 21:51:58 +02:00
Daniel Marjamäki
5de3c43209
changed id for new checker to unsafeClassDivZero
2017-10-21 21:45:04 +02:00
Daniel Marjamäki
15d814e609
classPublicInterfaceDivZero: Try to make the error message a bit better. Added variable name and what the bad input value is.
2017-10-21 13:00:52 +02:00
Daniel Marjamäki
299835da2f
classPublicInterfaceDivZero: don't warn in overloaded operators. It is normal behaviour that these are not protected.
2017-10-21 08:56:23 +02:00
Daniel Marjamäki
8a7411abdb
CheckClass: Fix wrong 'public interface' warnings
2017-10-20 22:10:55 +02:00
Dmitry-Me
5bf29fae49
Tests for unrecognized conversion specifiers
2017-10-20 21:46:24 +03:00
Dmitry-Me
4e881e98cc
Improve test coverage for %I used with printf
2017-10-20 21:13:14 +03:00
Daniel Marjamäki
1d5e3e4f0c
Fixed #8247 (False positive knownConditionTrueFalse)
2017-10-20 17:31:58 +02:00
Daniel Marjamäki
86c84029e3
New check: Check public interface of classes ( #8248 )
2017-10-20 02:02:51 +02:00
Dmitry-Me
7e2cef4952
Improve test coverage for %z used with printf
2017-10-19 19:05:16 +03:00
Dmitry-Me
f070fa1977
Improve test coverage for passing pointers into printf
2017-10-19 19:03:12 +03:00
Dmitry-Me
975132bc62
Improve test coverage for %td used with printf
2017-10-18 19:00:40 +03:00
Dmitry-Me
b278436069
Improve test coverage for %j used with printf
2017-10-18 18:22:51 +03:00
Dmitry-Me
a7d58a2468
Fix macro parameters list
2017-10-17 23:53:14 +03:00
Dmitry-Me
35a4822b77
Initial test coverage for %td used with scanf
2017-10-17 18:09:10 +03:00
Dmitry-Me
5beea50d3f
Improve test coverage for %ld, %lld, %I64x used with scanf
2017-10-17 18:07:42 +03:00
Daniel Marjamäki
ad1749738e
Fixed #6153 (ValueFlowBeforeCondition: Handle global variables)
2017-10-17 16:55:37 +02:00
Daniel Marjamäki
6d59290858
Fixed #10 (ValueFlow: condition variable has known value in switch case)
2017-10-16 21:51:30 +02:00
Dmitry-Me
f27e98f910
Fix macro parameters list
2017-10-16 18:49:53 +03:00
Daniel Marjamäki
0425f1d46d
Fixed #8241 (FP: Same expression on both sides of operator)
2017-10-16 17:39:50 +02:00
Dmitry-Me
2c61f40c35
Initial test coverage for %hd, %hhd, %jd, %I64d, %I32d used with scanf
2017-10-16 18:07:08 +03:00
Dmitry-Me
0ed8126b15
Tests for missing width specifier for scanf
2017-10-16 17:53:46 +03:00
Dmitry-Me
d6cac72784
Test for %I without width specifier used with printf
2017-10-16 17:51:38 +03:00
Robert Reif
69b75c43b4
SymbolDatabase: fix wrong type in union test.
2017-10-15 09:45:02 -04:00
IOBYTE
352fd7a381
SymbolDatabase: Add support for functions in unions. ( #973 )
2017-10-15 11:49:36 +02:00
Dmitry-Me
cad30446e4
Resolve C4800
2017-10-14 22:50:56 +03:00
Dmitry-Me
2c040096ca
Improve test coverage for va_end() called before va_start()
2017-10-14 19:28:26 +03:00
Dmitry-Me
b678f3c4c4
Improve test coverage for %c used with scanf_s
2017-10-13 19:08:14 +03:00
Dmitry-Me
d32a8884bf
Initial test coverage for %lx, %ld, %llx, %lld, %hx, %hhx, %Lx, %jx, %zx and %tx used with scanf
2017-10-13 18:36:12 +03:00
Dmitry-Me
7a7f34fb11
Improve test coverage for %zx, %zu used with printf
2017-10-13 18:17:33 +03:00
Dmitry-Me
d4a435a520
Tests for %Id, %Ld, %I32x used with scanf
2017-10-12 18:18:38 +03:00
Dmitry-Me
2a6f63d995
Resolve C4305 - double constant truncated to float
2017-10-11 23:36:51 +03:00
Dmitry-Me
d12db51771
Function parameter was not used
2017-10-11 00:43:50 +03:00
Daniel Marjamäki
f9d8dd9f4d
testsuite: don't compare doubles with !=
2017-10-10 22:40:49 +02:00
Dmitry-Me
e59ebed3b0
Remove rather unexpected empty line
2017-10-10 23:18:30 +03:00
Dmitry-Me
bef6d6f446
Improve test coverage for %I used with scanf
2017-10-10 17:27:33 +03:00
Dmitry-Me
fcba5b88c2
Improve test coverage for string literals passed as read target into scanf
2017-10-09 18:50:24 +03:00
Dmitry-Me
9c0e6986da
Passing string literals into printf as %p is fine
2017-10-08 11:14:10 +03:00
Ayaz Salikhov
be2c65eb58
Simplify int vs bool
2017-10-08 07:54:39 +02:00
Daniel Marjamäki
92673afc8f
fixed 'make checkcfg'
2017-10-06 15:16:25 +02:00
Daniel Marjamäki
e4676b70dd
Remove wrong testcase test/cfg/windows.cpp, there is missing configuration for that given code
2017-10-06 14:42:19 +02:00
Daniel Marjamäki
2a6fbe2e3c
astyle formatting
...
[ci skip]
2017-10-05 23:01:42 +02:00
hexcoder
051a18b120
pull request for ticket 8180 (better diagnostic output for bailouts) ( #964 )
...
* sync build instructions from readme.txt
* refactored the patch from ticket 8180. Moved logic from macros to the bailoutInternal function
* adapt to new bailout message format
* adapt to new bailout message format
* adapt to new bailout message format
* compile fix for Microsoft platform
* remove directory part from file locations in bailout message (normalize)
* remove directory part from valueflow message filter
* adapt tests to file format without directory part
* adapt tests to file format without directory part
* new line number agnostic assert_equals methods
* new line number agnostic assert_equals methods
* adapt to new method assertEqualsWithoutLineNumbers()
* adapt to new method assertEqualsWithoutLineNumbers()
* Bugfix: do not replace line number with spaces, remove it
* review changes: const char * -> std::string, size_t -> int, std::to_string() -> MathLib::toString()
* set #line at the beginning to guard against insertions from match compiler
* Bugfix: counting lines can be difficult :-) #line 1 -> #line 2
* added method stripDirectoryPart()
* added method stripDirectoryPart()
* used new method Path::stripDirectoryPart()
* new dependency path.h in lib/valueFlow.cpp
* code cleanup, removing redundant temporary objects and casts
2017-10-05 23:03:13 +02:00
Dmitry-Me
d170b496ba
Improve test coverage for wide string literals passed into printf
2017-10-05 17:45:06 +03:00