aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2011-02-12 00:19:56 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2011-02-12 00:19:56 +0000
commitd7401b35e3a4d08e43b4ab81dffd58099a37c90d (patch)
tree58b5e4f32ac3c9e5bad7d2dc0a387839e0a84bce /tools
parent776b7df0e7a91ab86a8aef59f3c896721cd597d9 (diff)
Fix a silly bug I introduced when dropping std::string.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125420 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r--tools/lto/LTOCodeGenerator.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/lto/LTOCodeGenerator.cpp b/tools/lto/LTOCodeGenerator.cpp
index d102f6b899..b2554f87b5 100644
--- a/tools/lto/LTOCodeGenerator.cpp
+++ b/tools/lto/LTOCodeGenerator.cpp
@@ -353,6 +353,7 @@ void LTOCodeGenerator::applyScopeRestrictions() {
SmallString<64> Buffer;
for (Module::iterator f = mergedModule->begin(),
e = mergedModule->end(); f != e; ++f) {
+ Buffer.clear();
mangler.getNameWithPrefix(Buffer, f, false);
if (!f->isDeclaration() &&
_mustPreserveSymbols.count(Buffer))
@@ -360,6 +361,7 @@ void LTOCodeGenerator::applyScopeRestrictions() {
}
for (Module::global_iterator v = mergedModule->global_begin(),
e = mergedModule->global_end(); v != e; ++v) {
+ Buffer.clear();
mangler.getNameWithPrefix(Buffer, v, false);
if (!v->isDeclaration() &&
_mustPreserveSymbols.count(Buffer))