mirror of
https://github.com/docker/docs.git
synced 2026-03-30 07:48:52 +07:00
fix panic in monitor
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com> (github: vieux)
This commit is contained in:
@@ -785,7 +785,7 @@ func (container *Container) monitor(callback execdriver.StartCallback) error {
|
||||
utils.Errorf("Error running container: %s", err)
|
||||
}
|
||||
|
||||
if container.runtime.srv.IsRunning() {
|
||||
if container.runtime != nil && container.runtime.srv != nil && container.runtime.srv.IsRunning() {
|
||||
container.State.SetStopped(exitCode)
|
||||
|
||||
// FIXME: there is a race condition here which causes this to fail during the unit tests.
|
||||
|
||||
Reference in New Issue
Block a user