mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-25 21:18:19 +00:00
Avoid using PathV1.h in Program.h.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183940 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -61,11 +61,7 @@ static int RunProgramWithTimeout(StringRef ProgramPath,
|
||||
unsigned NumSeconds = 0,
|
||||
unsigned MemoryLimit = 0,
|
||||
std::string *ErrMsg = 0) {
|
||||
const sys::Path P[3] = { sys::Path(StdInFile), sys::Path(StdOutFile),
|
||||
sys::Path(StdErrFile) };
|
||||
const sys::Path* redirects[3];
|
||||
for (int I = 0; I < 3; ++I)
|
||||
redirects[I] = &P[I];
|
||||
const StringRef *Redirects[3] = { &StdInFile, &StdOutFile, &StdErrFile };
|
||||
|
||||
#if 0 // For debug purposes
|
||||
{
|
||||
@@ -76,7 +72,7 @@ static int RunProgramWithTimeout(StringRef ProgramPath,
|
||||
}
|
||||
#endif
|
||||
|
||||
return sys::ExecuteAndWait(sys::Path(ProgramPath), Args, 0, redirects,
|
||||
return sys::ExecuteAndWait(ProgramPath, Args, 0, Redirects,
|
||||
NumSeconds, MemoryLimit, ErrMsg);
|
||||
}
|
||||
|
||||
@@ -93,11 +89,7 @@ static int RunProgramRemotelyWithTimeout(StringRef RemoteClientPath,
|
||||
StringRef StdErrFile,
|
||||
unsigned NumSeconds = 0,
|
||||
unsigned MemoryLimit = 0) {
|
||||
const sys::Path P[3] = { sys::Path(StdInFile), sys::Path(StdOutFile),
|
||||
sys::Path(StdErrFile) };
|
||||
const sys::Path* redirects[3];
|
||||
for (int I = 0; I < 3; ++I)
|
||||
redirects[I] = &P[I];
|
||||
const StringRef *Redirects[3] = { &StdInFile, &StdOutFile, &StdErrFile };
|
||||
|
||||
#if 0 // For debug purposes
|
||||
{
|
||||
@@ -109,8 +101,8 @@ static int RunProgramRemotelyWithTimeout(StringRef RemoteClientPath,
|
||||
#endif
|
||||
|
||||
// Run the program remotely with the remote client
|
||||
int ReturnCode = sys::ExecuteAndWait(sys::Path(RemoteClientPath), Args, 0,
|
||||
redirects, NumSeconds, MemoryLimit);
|
||||
int ReturnCode = sys::ExecuteAndWait(RemoteClientPath, Args, 0,
|
||||
Redirects, NumSeconds, MemoryLimit);
|
||||
|
||||
// Has the remote client fail?
|
||||
if (255 == ReturnCode) {
|
||||
|
||||
Reference in New Issue
Block a user