mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-13 10:06:33 +01:00
Allow to get exit status from child processes
This commit is contained in:
parent
d48b9af810
commit
abbf1ca698
1 changed files with 6 additions and 2 deletions
|
|
@ -431,7 +431,11 @@ SystemExec::wait (int options)
|
||||||
while (is_running()) {
|
while (is_running()) {
|
||||||
WaitForSingleObject(pid->hProcess, 40);
|
WaitForSingleObject(pid->hProcess, 40);
|
||||||
}
|
}
|
||||||
return 0;
|
DWORD exit_code;
|
||||||
|
if (GetExitCodeProcess(pid->hProcess, &exit_code)) {
|
||||||
|
return exit_code;
|
||||||
|
}
|
||||||
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
|
|
@ -707,7 +711,7 @@ SystemExec::wait (int options)
|
||||||
}
|
}
|
||||||
} /* else the process is still running */
|
} /* else the process is still running */
|
||||||
}
|
}
|
||||||
return status;
|
return WEXITSTATUS (status);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue