From 028374b99e5c9dd23236a10495ea0aebe819b51f Mon Sep 17 00:00:00 2001 From: Matthew Heon Date: Fri, 13 Jul 2018 10:24:17 -0400 Subject: Record whether the container has exited Use this to supplement exit codes returned from containers, to make sure we know when exit codes are invalid (as the container has not yet exited) Signed-off-by: Matthew Heon --- libpod/container_internal.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libpod/container_internal.go') diff --git a/libpod/container_internal.go b/libpod/container_internal.go index 905402c47..010d01315 100644 --- a/libpod/container_internal.go +++ b/libpod/container_internal.go @@ -586,6 +586,8 @@ func (c *Container) reinit(ctx context.Context) error { // Set and save now to make sure that, if the init() below fails // we still have a valid state c.state.State = ContainerStateConfigured + c.state.ExitCode = 0 + c.state.Exited = false if err := c.save(); err != nil { return err } -- cgit v1.2.3-54-g00ecf