[PATCH] D141389: [DFSAN] Add support for strnlen, strncat, strsep, sscanf and _tolower
Andrew via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 13 09:57:11 PDT 2023
browneee accepted this revision.
browneee added a comment.
This revision is now accepted and ready to land.
Please fix the additional &.
Do you need me to submit it for you?
================
Comment at: compiler-rt/test/dfsan/custom.cpp:1645
+ // taint the string pointer
+ dfsan_set_label(m_label, &p_s, sizeof(&p_s));
+
----------------
Remove & in sizeof.
================
Comment at: compiler-rt/test/dfsan/custom.cpp:1641
+ // taint delim pointer
+ dfsan_set_label(j_label, &p_delim, sizeof(&p_delim));
+ // taint the string data bytes
----------------
browneee wrote:
> remove the &
>
> It still works because `sizeof(pointer_var) == sizeof(&pointer_var)`, but it doesn't logically match up like it should.
>
> (Sorry, this one is my fault - I made this mistake giving an example in an earlier comment.)
Remove & in sizeof.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D141389/new/
https://reviews.llvm.org/D141389
More information about the cfe-commits
mailing list