summaryrefslogtreecommitdiffstats
path: root/llvm/tools
diff options
context:
space:
mode:
authorFangrui Song <maskray@google.com>2018-11-12 23:46:22 +0000
committerFangrui Song <maskray@google.com>2018-11-12 23:46:22 +0000
commite9f34b0d521f96669217656fa8162336a7d3f00a (patch)
treebde36df2debf44a187f742178b744df6d5067bd9 /llvm/tools
parent35b1c2d19db5ba9e8340b4049f0f5283ed022279 (diff)
downloadbcm5719-llvm-e9f34b0d521f96669217656fa8162336a7d3f00a.tar.gz
bcm5719-llvm-e9f34b0d521f96669217656fa8162336a7d3f00a.zip
[llvm-objcopy] Don't copy Config when processing --keep
llvm-svn: 346717
Diffstat (limited to 'llvm/tools')
-rw-r--r--llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp b/llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp
index a367a30c467..05985d3d2f1 100644
--- a/llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp
+++ b/llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp
@@ -386,7 +386,7 @@ static void handleArgs(const CopyConfig &Config, Object &Obj,
}
if (!Config.Keep.empty()) {
- RemovePred = [Config, RemovePred](const SectionBase &Sec) {
+ RemovePred = [&Config, RemovePred](const SectionBase &Sec) {
// Explicitly keep these sections regardless of previous removes.
if (is_contained(Config.Keep, Sec.Name))
return false;
OpenPOWER on IntegriCloud