[PATCH] D45625: [llvm-exegesis] Fix use after free.
Clement Courbet via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 13 07:46:15 PDT 2018
courbet created this revision.
courbet added a reviewer: gchatelet.
Herald added a subscriber: tschuett.
Repository:
rL LLVM
https://reviews.llvm.org/D45625
Files:
tools/llvm-exegesis/lib/InMemoryAssembler.cpp
Index: tools/llvm-exegesis/lib/InMemoryAssembler.cpp
===================================================================
--- tools/llvm-exegesis/lib/InMemoryAssembler.cpp
+++ tools/llvm-exegesis/lib/InMemoryAssembler.cpp
@@ -215,7 +215,7 @@
// Adding the generated object file containing the assembled function.
// The ExecutionEngine makes sure the object file is copied into an
// executable page.
- ExecEngine->addObjectFile(ObjHolder.takeBinary().first);
+ ExecEngine->addObjectFile(std::move(ObjHolder));
// Setting function
FunctionBytes =
llvm::StringRef(reinterpret_cast<const char *>(
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D45625.142409.patch
Type: text/x-patch
Size: 618 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180413/c427a6fe/attachment-0001.bin>
More information about the llvm-commits
mailing list