projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e8d826b
)
bugpoint/ToolRunner.cpp: ProcessFailure(): Close ErrorFD immediately, or it couldn...
author
NAKAMURA Takumi
<geek4civic@gmail.com>
Sun, 13 Jul 2014 13:28:18 +0000
(13:28 +0000)
committer
NAKAMURA Takumi
<geek4civic@gmail.com>
Sun, 13 Jul 2014 13:28:18 +0000
(13:28 +0000)
FIXME: We may have an option in openFileForWrite(), not to use ResultFD but to close it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212902
91177308
-0d34-0410-b5e6-
96231b3b80d8
tools/bugpoint/ToolRunner.cpp
patch
|
blob
|
history
diff --git
a/tools/bugpoint/ToolRunner.cpp
b/tools/bugpoint/ToolRunner.cpp
index 4a2401b530f52ea63747cfe40adc867145d222aa..a28b2856f1e9cf0683e95ab91ace29c52b6f936a 100644
(file)
--- a/
tools/bugpoint/ToolRunner.cpp
+++ b/
tools/bugpoint/ToolRunner.cpp
@@
-148,6
+148,14
@@
static std::string ProcessFailure(StringRef ProgPath, const char** Args,
errs() << "Error making unique filename: " << EC.message() << "\n";
exit(1);
}
+
+#ifdef _WIN32
+ // Close ErrorFD immediately, or it couldn't be reopened on Win32.
+ // FIXME: We may have an option in openFileForWrite(), not to use ResultFD
+ // but to close it.
+ delete new raw_fd_ostream(ErrorFD, true);
+#endif
+
RunProgramWithTimeout(ProgPath, Args, "", ErrorFilename.str(),
ErrorFilename.str(), Timeout, MemoryLimit);
// FIXME: check return code ?