[PATCH] D71566: New checks for fortified sprintf
serge via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Dec 17 05:42:21 PST 2019
serge-sans-paille marked 2 inline comments as done.
serge-sans-paille added inline comments.
================
Comment at: clang/lib/Sema/SemaChecking.cpp:392
+ EstimateSizeFormatHandler H(StrE);
+ StringRef StrRef = StrE->getString();
+ const char *Str = StrRef.data();
----------------
serge-sans-paille wrote:
> erik.pilkington wrote:
> > Will this assert on: `sprintf(buf, L"foo");`? Not that that makes any sense, but we shouldn't crash.
> Still need to check that.
Checked and fixed!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D71566/new/
https://reviews.llvm.org/D71566
More information about the cfe-commits
mailing list