File tree Expand file tree Collapse file tree
src/Likely Bugs/Memory Management
test/query-tests/Likely Bugs/Memory Management/PointerOverflow Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2525 not exists ( MacroInvocation mi |
2626 mi .getAnAffectedElement ( ) = add and
2727 not mi .getMacroName ( ) .toLowerCase ( ) .matches ( "%assert%" )
28+ ) and
29+ // There must be a compilation of this file without a flag that makes pointer
30+ // overflow well defined.
31+ exists ( Compilation c | c .getAFileCompiled ( ) = ro .getFile ( ) |
32+ not c .getAnArgument ( ) = "-fwrapv-pointer" and
33+ not c .getAnArgument ( ) = "-fno-strict-overflow"
2834 )
29- // TODO: Add a check for -fno-strict-overflow and -fwrapv-pointer
3035select ro , "Range check relying on pointer overflow."
Original file line number Diff line number Diff line change 1- | no_strict_overflow.c:5:9:5:21 | ... < ... | Range check relying on pointer overflow. |
21| test.cpp:6:12:6:33 | ... < ... | Range check relying on pointer overflow. |
32| test.cpp:33:9:33:21 | ... < ... | Range check relying on pointer overflow. |
You can’t perform that action at this time.
0 commit comments