Skip to content

Commit

Permalink
Use Windows-compatible ExitStatus in Executor.Wait
Browse files Browse the repository at this point in the history
Signed-off-by: Peng Peng <[email protected]>
Signed-off-by: Peng Peng <[email protected]>
  • Loading branch information
Peng Peng authored and ppbits committed Dec 6, 2024
1 parent d263f4d commit 9318eac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ func (e *Executor) Wait(ctx context.Context) (*ExecResult, error) {

if err != nil {
if exit, ok := err.(*exec.ExitError); ok {
res.ExitStatus = int(exit.ProcessState.Sys().(syscall.WaitStatus) / 256)
res.ExitStatus = exit.ProcessState.Sys().(syscall.WaitStatus).ExitStatus()
}
}

Expand Down

0 comments on commit 9318eac

Please sign in to comment.