mirror of
https://github.com/intel/llvm.git
synced 2026-01-30 22:53:05 +08:00
Handle the possible case where the process launch failed
but we don't have an error message. llvm-svn: 134662
This commit is contained in:
@@ -228,12 +228,18 @@ RNBRunLoopLaunchInferior (RNBRemote *remote, const char *stdin_path, const char
|
||||
|
||||
g_pid = pid;
|
||||
|
||||
if (pid == INVALID_NUB_PROCESS && strlen(launch_err_str) > 0)
|
||||
if (pid == INVALID_NUB_PROCESS && strlen (launch_err_str) > 0)
|
||||
{
|
||||
DNBLogThreaded ("%s DNBProcessLaunch() returned error: '%s'", __FUNCTION__, launch_err_str);
|
||||
ctx.LaunchStatus().SetError(-1, DNBError::Generic);
|
||||
ctx.LaunchStatus().SetErrorString(launch_err_str);
|
||||
}
|
||||
else if (pid == INVALID_NUB_PROCESS)
|
||||
{
|
||||
DNBLogThreaded ("%s DNBProcessLaunch() failed to launch process, unknown failure", __FUNCTION__);
|
||||
ctx.LaunchStatus().SetError(-1, DNBError::Generic);
|
||||
ctx.LaunchStatus().SetErrorString(launch_err_str);
|
||||
}
|
||||
else
|
||||
{
|
||||
ctx.LaunchStatus().Clear();
|
||||
|
||||
Reference in New Issue
Block a user