[PATCH] D16188: LLVMRunStaticConstructors can be called before object is finalized, #24028

Amaury SECHET via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 14 16:27:24 PST 2016


This revision was automatically updated to reflect the committed changes.
Closed by commit rL257849: LLVMRunStaticConstructors can be called before object is finalized, #24028 (authored by deadalnix).

Changed prior to commit:
  http://reviews.llvm.org/D16188?vs=44882&id=44944#toc

Repository:
  rL LLVM

http://reviews.llvm.org/D16188

Files:
  llvm/trunk/lib/ExecutionEngine/ExecutionEngineBindings.cpp

Index: llvm/trunk/lib/ExecutionEngine/ExecutionEngineBindings.cpp
===================================================================
--- llvm/trunk/lib/ExecutionEngine/ExecutionEngineBindings.cpp
+++ llvm/trunk/lib/ExecutionEngine/ExecutionEngineBindings.cpp
@@ -215,10 +215,12 @@
 }
 
 void LLVMRunStaticConstructors(LLVMExecutionEngineRef EE) {
+  unwrap(EE)->finalizeObject();
   unwrap(EE)->runStaticConstructorsDestructors(false);
 }
 
 void LLVMRunStaticDestructors(LLVMExecutionEngineRef EE) {
+  unwrap(EE)->finalizeObject();
   unwrap(EE)->runStaticConstructorsDestructors(true);
 }
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D16188.44944.patch
Type: text/x-patch
Size: 595 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160115/9b524ee1/attachment.bin>


More information about the llvm-commits mailing list