[PATCH] D91299: [clangd] Also detect corrupt stri table size.
Kadir Cetinkaya via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 11 13:45:28 PST 2020
kadircet accepted this revision.
kadircet added inline comments.
This revision is now accepted and ready to land.
================
Comment at: clang-tools-extra/clangd/index/Serialization.cpp:209
+ // Theoretical max ratio from https://zlib.net/zlib_tech.html
+ constexpr int MaxCompressionRatio = 1032;
+ if (UncompressedSize / MaxCompressionRatio > R.rest().size())
----------------
we also need a static here.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91299/new/
https://reviews.llvm.org/D91299
More information about the cfe-commits
mailing list