Merge pull request #24259 from emakrushin/containers
Unlock mutex before returning from function
This commit is contained in:
commit
3fbae8e28e
|
@ -467,6 +467,7 @@ func (ic *ContainerEngine) ContainerRm(ctx context.Context, namesOrIds []string,
|
||||||
errMap, err := parallelctr.ContainerOp(ctx, libpodContainers, func(c *libpod.Container) error {
|
errMap, err := parallelctr.ContainerOp(ctx, libpodContainers, func(c *libpod.Container) error {
|
||||||
mapMutex.Lock()
|
mapMutex.Lock()
|
||||||
if _, ok := ctrsMap[c.ID()]; ok {
|
if _, ok := ctrsMap[c.ID()]; ok {
|
||||||
|
mapMutex.Unlock()
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
mapMutex.Unlock()
|
mapMutex.Unlock()
|
||||||
|
|
Loading…
Reference in New Issue