[PATCH] D70411: [analyzer][WIP] StrChecker: 31.c

2019-11-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I think it would really help if you draw a state machine for the checker, like the ASCII-art thing in D70470 ; you don't need to spend a lot of time turning it into ASCII-art, a photo of a quick hand-drawn picture would be totally fine,

[PATCH] D70411: [analyzer][WIP] StrChecker: 31.c

2019-11-20 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D70411#1750690 , @Charusso wrote: > Somehow the `MallocBugVisitor` is broken in the wild - it does not catch the > allocation, and we need to support a lot more to call it non-alpha (see the > `FIXME`s). I do not want

[PATCH] D70411: [analyzer][WIP] StrChecker: 31.c

2019-11-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/cert/StrChecker.cpp:279 +if (PredNode->getState() == ErrorNode->getState()) { + IsFalsePositiveFound = true; + PR->markInvalid(nullptr, nullptr); Why is this a

[PATCH] D70411: [analyzer][WIP] StrChecker: 31.c

2019-11-18 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso marked an inline comment as done. Charusso added a comment. Somehow the `MallocBugVisitor` is broken in the wild, and we need to support a lot more to call it non-alpha (see the `FIXME`s). I do not want to spend time on fixing the visitor, but rather I would make this checker alpha,

[PATCH] D70411: [analyzer][WIP] StrChecker: 31.c

2019-11-18 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso created this revision. Charusso added a reviewer: NoQ. Charusso added a project: clang. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun, mgorny. This checker warns on most of the following rules: