mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #40594 from sfzhu93/Mis_Unlock
daemon/cluster: add a missing Unlock
This commit is contained in:
commit
40b2b4b083
1 changed files with 1 additions and 0 deletions
|
@ -33,6 +33,7 @@ func (c *Cluster) Init(req types.InitRequest) (string, error) {
|
|||
// API handlers to finish before shutting down the node.
|
||||
c.mu.Lock()
|
||||
if !c.nr.nodeState.IsManager() {
|
||||
c.mu.Unlock()
|
||||
return "", errSwarmNotManager
|
||||
}
|
||||
c.mu.Unlock()
|
||||
|
|
Loading…
Add table
Reference in a new issue