[PATCH] D97239: [profile] Fix buffer overrun when parsing %c in filename string

Shafik Yaghmour via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 24 15:04:23 PST 2021


shafik added inline comments.


================
Comment at: compiler-rt/lib/profile/InstrProfilingFile.c:776
         __llvm_profile_enable_continuous_mode();
-        I++; /* advance to 'c' */
       } else {
         unsigned MergePoolSize = getMergePoolSize(FilenamePat, &I);
----------------
Obviously not for this PR but it seems unwise we don't actually verify `FilenamePat[I] == 'm'`


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97239/new/

https://reviews.llvm.org/D97239



More information about the llvm-commits mailing list