diff options
author | baude <bbaude@redhat.com> | 2018-02-26 16:26:04 -0600 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-02-26 23:18:36 +0000 |
commit | f47a5be60d91fd2055ed6afbb6bb014c9635f2df (patch) | |
tree | cb58ae7f16f88590119c71a513e96a24280ec844 /cmd/podman/ps.go | |
parent | e5ddf34e648c6bf431e062c90b067f5eb8a3beb0 (diff) | |
download | podman-f47a5be60d91fd2055ed6afbb6bb014c9635f2df.tar.gz podman-f47a5be60d91fd2055ed6afbb6bb014c9635f2df.tar.bz2 podman-f47a5be60d91fd2055ed6afbb6bb014c9635f2df.zip |
ps displays incorrect exit code
The exit code should be derived in the batch operation and pulled
from the batchinfo struct.
Resolves issue #407
Signed-off-by: baude <bbaude@redhat.com>
Closes: #408
Approved by: rhatdan
Diffstat (limited to 'cmd/podman/ps.go')
-rw-r--r-- | cmd/podman/ps.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/podman/ps.go b/cmd/podman/ps.go index b635ea392..14da06ae8 100644 --- a/cmd/podman/ps.go +++ b/cmd/podman/ps.go @@ -441,7 +441,7 @@ func getTemplateOutput(containers []*libpod.Container, opts psOptions) ([]psTemp switch batchInfo.conState { case libpod.ContainerStateStopped: - status = fmt.Sprintf("Exited (%d) %s ago", exitCode, runningFor) + status = fmt.Sprintf("Exited (%d) %s ago", batchInfo.exitCode, runningFor) case libpod.ContainerStateRunning: status = "Up " + runningFor + " ago" case libpod.ContainerStatePaused: |