diff --git a/llvm/tools/llvm-ld/llvm-ld.cpp b/llvm/tools/llvm-ld/llvm-ld.cpp index a7f15a9c3fcd..60fe746b7a4a 100644 --- a/llvm/tools/llvm-ld/llvm-ld.cpp +++ b/llvm/tools/llvm-ld/llvm-ld.cpp @@ -499,7 +499,7 @@ int main(int argc, char **argv, char **envp) { // Get the program arguments sys::Path tmp_output("opt_result"); std::string ErrMsg; - if (tmp_output.createTemporaryFileOnDisk(true)) { + if (tmp_output.createTemporaryFileOnDisk(true, &ErrMsg)) { return PrintAndReturn(ErrMsg); } const char* args[4];