mirror of
https://github.com/tailscale/tailscale.git
synced 2025-01-07 08:07:42 +00:00
wgengine/magicsock: call peerMap.validate at the end of SetNetworkMap
Not for prod, maybe useful for debugging.
This commit is contained in:
parent
2bef8ecece
commit
aec281e638
@ -2264,6 +2264,11 @@ func nodesEqual(x, y []*tailcfg.Node) bool {
|
||||
func (c *Conn) SetNetworkMap(nm *netmap.NetworkMap) {
|
||||
c.mu.Lock()
|
||||
defer c.mu.Unlock()
|
||||
defer func() {
|
||||
if err := c.peerMap.validate(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
}()
|
||||
|
||||
if c.closed {
|
||||
return
|
||||
|
Loading…
x
Reference in New Issue
Block a user