StopPodSandbox should not log when container is already removed
This commit is contained in:
@@ -239,9 +239,9 @@ func (ds *dockerService) StopPodSandbox(podSandboxID string) error {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if err := ds.client.StopContainer(podSandboxID, defaultSandboxGracePeriod); err != nil {
|
if err := ds.client.StopContainer(podSandboxID, defaultSandboxGracePeriod); err != nil {
|
||||||
glog.Errorf("Failed to stop sandbox %q: %v", podSandboxID, err)
|
|
||||||
// Do not return error if the container does not exist
|
// Do not return error if the container does not exist
|
||||||
if !libdocker.IsContainerNotFoundError(err) {
|
if !libdocker.IsContainerNotFoundError(err) {
|
||||||
|
glog.Errorf("Failed to stop sandbox %q: %v", podSandboxID, err)
|
||||||
errList = append(errList, err)
|
errList = append(errList, err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user