conmon: Return the exit status code
waitpid fills its second argument with a value that contains the process exit code in the 8 least significant bits. Instead of returning the complete value and then convert it from ocid, return the exit status directly by using WEXITSTATUS from conmon. Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
parent
61e60bfe47
commit
9a4a1092fe
3 changed files with 5 additions and 8 deletions
|
@ -125,8 +125,3 @@ func dockerRemove(container string) error {
|
|||
_, err := ExecCmd("docker", "rm", container)
|
||||
return err
|
||||
}
|
||||
|
||||
// StatusToExitCode converts wait status code to an exit code
|
||||
func StatusToExitCode(status int) int {
|
||||
return ((status) & 0xff00) >> 8
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue