mibintc created this revision. mibintc added a reviewer: majnemer. Herald added a project: clang. mibintc requested review of this revision.
Fix off-by-one bug in determining the threshold for when want to shorten very large external names, Microsoft compatibility. This fixes the bug reported here, https://bugs.llvm.org/show_bug.cgi?id=38868 Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D90714 Files: clang/lib/AST/MicrosoftMangle.cpp Index: clang/lib/AST/MicrosoftMangle.cpp =================================================================== --- clang/lib/AST/MicrosoftMangle.cpp +++ clang/lib/AST/MicrosoftMangle.cpp @@ -50,7 +50,7 @@ bool StartsWithEscape = MangledName.startswith("\01"); if (StartsWithEscape) MangledName = MangledName.drop_front(1); - if (MangledName.size() <= 4096) { + if (MangledName.size() < 4096) { OS << str(); return; }
Index: clang/lib/AST/MicrosoftMangle.cpp =================================================================== --- clang/lib/AST/MicrosoftMangle.cpp +++ clang/lib/AST/MicrosoftMangle.cpp @@ -50,7 +50,7 @@ bool StartsWithEscape = MangledName.startswith("\01"); if (StartsWithEscape) MangledName = MangledName.drop_front(1); - if (MangledName.size() <= 4096) { + if (MangledName.size() < 4096) { OS << str(); return; }
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits