mirror of
https://github.com/moby/moby.git
synced 2026-08-03 22:51:03 +00:00
Merge pull request #26124 from darrenstahlmsft/RestoreLock
Lock concurrent access to remove map during Daemon restore
This commit is contained in:
@@ -201,7 +201,9 @@ func (daemon *Daemon) restore() error {
|
||||
restartContainers[c] = make(chan struct{})
|
||||
mapLock.Unlock()
|
||||
} else if c.HostConfig != nil && c.HostConfig.AutoRemove {
|
||||
mapLock.Lock()
|
||||
removeContainers[c.ID] = c
|
||||
mapLock.Unlock()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user