1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Cleanup the cluster provider when the agent is closed

Signed-off-by: Kyle Wuolle <kyle.wuolle@gmail.com>
This commit is contained in:
Kyle Wuolle 2019-01-24 15:45:13 -08:00
parent b0bef06dca
commit 7ca0bc66d3

View file

@ -378,6 +378,9 @@ func (c *controller) agentClose() {
c.agent = nil
c.Unlock()
// when the agent is closed the cluster provider should be cleaned up
c.SetClusterProvider(nil)
if agent == nil {
return
}