devnexen added a comment.
In https://reviews.llvm.org/D45177#1103781, @alexfh wrote:
> In https://reviews.llvm.org/D45177#1103774, @devnexen wrote:
>
> > In https://reviews.llvm.org/D45177#1103162, @alexfh wrote:
> >
> > > See https://bugs.llvm.org/show_bug.cgi?id=37503 for a test case.
> >
> >
>
devnexen added a comment.
I admit I do not due to much longer compilation time, I ll recompile all with
and will see tomorrow if I can reproduce.
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists
alexfh added a comment.
In https://reviews.llvm.org/D45177#1103774, @devnexen wrote:
> In https://reviews.llvm.org/D45177#1103162, @alexfh wrote:
>
> > See https://bugs.llvm.org/show_bug.cgi?id=37503 for a test case.
>
>
> I was unable to reproduce both FreeBSD and Linux. Plus my changes come aft
devnexen added a comment.
In https://reviews.llvm.org/D45177#1103162, @alexfh wrote:
> See https://bugs.llvm.org/show_bug.cgi?id=37503 for a test case.
I was unable to reproduce both FreeBSD and Linux. Plus my changes come after
checkNonNull.
Repository:
rC Clang
https://reviews.llvm.org/
alexfh added a comment.
See https://bugs.llvm.org/show_bug.cgi?id=37503 for a test case.
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/c
devnexen added a comment.
In https://reviews.llvm.org/D45177#1102887, @alexfh wrote:
> This is reproducible in r332425.
I posted this PR https://reviews.llvm.org/D47007 hopes it helps.
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
c
alexfh added a comment.
This is reproducible in r332425.
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
alexfh added a comment.
This patch seems to cause an assertion failure:
assert.h assertion failed at clang/lib/StaticAnalyzer/Core/SValBuilder.cpp:427
in clang::ento::SVal
clang::ento::SValBuilder::evalBinOp(clang::ento::ProgramStateRef,
BinaryOperator::Opcode, clang::ento::SVal, clang::ento::
devnexen added inline comments.
Comment at: lib/StaticAnalyzer/Checkers/CStringChecker.cpp:1560-1566
// If the size is known to be zero, we're done.
if (StateZeroSize && !StateNonZeroSize) {
StateZeroSize = StateZeroSize->BindExpr(CE, LCtx, DstVal);
NoQ added inline comments.
Comment at: lib/StaticAnalyzer/Checkers/CStringChecker.cpp:1560-1566
// If the size is known to be zero, we're done.
if (StateZeroSize && !StateNonZeroSize) {
StateZeroSize = StateZeroSize->BindExpr(CE, LCtx, DstVal);
This revision was automatically updated to reflect the committed changes.
Closed by commit rC332303: [analyzer] Re-apply r331096 "CStringChecker:
Add support for BSD strlcpy()...". (authored by dergachev, committed by ).
Repository:
rC Clang
https://reviews.llvm.org/D45177
Files:
lib/Static
NoQ accepted this revision.
NoQ added a comment.
This revision is now accepted and ready to land.
Thanks! I'll commit again.
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailma
devnexen added a comment.
Thanks ! I would be grateful if anybody could land it for me.
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
rja accepted this revision.
rja added a comment.
LG
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
devnexen added a comment.
ping
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
devnexen added inline comments.
Comment at: lib/StaticAnalyzer/Checkers/CStringChecker.cpp:1485
+ state = CheckOverlap(C, state, CE->getArg(2), Dst, srcExpr);
+
NoQ wrote:
> This crashes on the old tests for the checker. I guess that's because the
> normal `s
devnexen updated this revision to Diff 145352.
https://reviews.llvm.org/D45177
Files:
lib/StaticAnalyzer/Checkers/CStringChecker.cpp
test/Analysis/bsd-string.c
Index: test/Analysis/bsd-string.c
===
--- /dev/null
+++ test/Analysi
NoQ added inline comments.
Comment at: lib/StaticAnalyzer/Checkers/CStringChecker.cpp:1485
+ state = CheckOverlap(C, state, CE->getArg(2), Dst, srcExpr);
+
This crashes on the old tests for the checker. I guess that's because the
normal `strcpy()` doesn't hav
devnexen updated this revision to Diff 144981.
devnexen added a comment.
New test to check the length
https://reviews.llvm.org/D45177
Files:
lib/StaticAnalyzer/Checkers/CStringChecker.cpp
test/Analysis/bsd-string.c
Index: test/Analysis/bsd-string.c
=
NoQ added a comment.
Yay that was fast, thanks!
Could we have tests for the return value? Like, concatenate a couple of
concrete string literals and verify the return value via
`clang_analyzer_eval()`.
https://reviews.llvm.org/D45177
___
cfe-comm
devnexen updated this revision to Diff 144952.
devnexen added a comment.
The returned value is the number of character copied to the dst buffer.
https://reviews.llvm.org/D45177
Files:
lib/StaticAnalyzer/Checkers/CStringChecker.cpp
test/Analysis/bsd-string.c
Index: test/Analysis/bsd-string.
devnexen added a comment.
Sure ! looking into it.
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
NoQ reopened this revision.
NoQ added a comment.
This revision is now accepted and ready to land.
I reverted this for now. I'm sorry - i would have looked into this myself, but
unfortunately there are other important fixes that distract me at the moment.
Repository:
rC Clang
https://reviews.
NoQ added a comment.
Whoops - this isn't quite correct because there's one more difference between
strlcpy/strlcat and the standard strcpy/strcat/strncpy/strncat: the return
value. After this patch the new functions are modeled as if they return a
pointer into the string, which is incorrect and
NoQ added inline comments.
Comment at: lib/StaticAnalyzer/Checkers/CStringChecker.cpp:106
+bool isAppending,
+bool canOverlap = false) const;
The fact that the regular `strcpy`/`strcat` isn't checked for overlaps
This revision was automatically updated to reflect the committed changes.
Closed by commit rC331096: [analyzer] CStringChecker: Add support for BSD
strlcpy() and strlcat(). (authored by dergachev, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D45177?vs=140667&id=144421#toc
devnexen added a comment.
If anybody can land for me, I would appreciate. Thanks regardless :-)
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/lis
devnexen added a comment.
ping
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
devnexen added a comment.
ping
Repository:
rC Clang
https://reviews.llvm.org/D45177
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
devnexen created this revision.
devnexen added reviewers: george.karpenkov, NoQ.
Herald added a subscriber: cfe-commits.
strlcpy/strlcat are bounded but unlike their strn* counterparts, they can
overlap.
Repository:
rC Clang
https://reviews.llvm.org/D45177
Files:
lib/StaticAnalyzer/Checke
30 matches
Mail list logo