mirror of
https://github.com/netbirdio/netbird.git
synced 2025-06-20 09:47:49 +02:00
Fix error state race on mgmt connection error (#2892)
This commit is contained in:
parent
582bb58714
commit
a7d5c52203
@ -157,7 +157,8 @@ func (c *ConnectClient) run(mobileDependency MobileDependency, probes *ProbeHold
|
|||||||
|
|
||||||
engineCtx, cancel := context.WithCancel(c.ctx)
|
engineCtx, cancel := context.WithCancel(c.ctx)
|
||||||
defer func() {
|
defer func() {
|
||||||
c.statusRecorder.MarkManagementDisconnected(state.err)
|
_, err := state.Status()
|
||||||
|
c.statusRecorder.MarkManagementDisconnected(err)
|
||||||
c.statusRecorder.CleanLocalPeerState()
|
c.statusRecorder.CleanLocalPeerState()
|
||||||
cancel()
|
cancel()
|
||||||
}()
|
}()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user