Revert "Turn some C-style vararg into variadic templates"
This reverts commit r299699, the examples needs to be updated. llvm-svn: 299702
This commit is contained in:
@@ -481,15 +481,16 @@ BasicBlock *StackProtector::CreateFailBB() {
|
||||
IRBuilder<> B(FailBB);
|
||||
B.SetCurrentDebugLocation(DebugLoc::get(0, 0, F->getSubprogram()));
|
||||
if (Trip.isOSOpenBSD()) {
|
||||
Constant *StackChkFail = M->getOrInsertFunction(
|
||||
"__stack_smash_handler", Type::getVoidTy(Context),
|
||||
Type::getInt8PtrTy(Context));
|
||||
Constant *StackChkFail =
|
||||
M->getOrInsertFunction("__stack_smash_handler",
|
||||
Type::getVoidTy(Context),
|
||||
Type::getInt8PtrTy(Context), nullptr);
|
||||
|
||||
B.CreateCall(StackChkFail, B.CreateGlobalStringPtr(F->getName(), "SSH"));
|
||||
} else {
|
||||
Constant *StackChkFail =
|
||||
M->getOrInsertFunction("__stack_chk_fail", Type::getVoidTy(Context));
|
||||
|
||||
M->getOrInsertFunction("__stack_chk_fail", Type::getVoidTy(Context),
|
||||
nullptr);
|
||||
B.CreateCall(StackChkFail, {});
|
||||
}
|
||||
B.CreateUnreachable();
|
||||
|
||||
Reference in New Issue
Block a user