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

2019-11-20 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/cert/StrChecker.cpp:170 +Report->addVisitor( +allocation_state::getMallocBRVisitor(DestV.getAsSymbol())); + } else { We can do the opposite to see whether the destination a

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

2019-11-20 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso added a comment. In D70411#1754356 , @NoQ wrote: > 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

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

2019-11-20 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso updated this revision to Diff 230354. Charusso marked 2 inline comments as done. Charusso retitled this revision from "[analyzer][WIP] StrChecker: 31.c" to "[analyzer][WIP] CERT: StrChecker: 31.c". Charusso added a comment. - Added a report when the not null-terminated string is read. -