wgengine/magicsock: update netmap cache flag on receipt of a delta (#20117)

Since deltas are only (at present) received from the control plane, processing
a delta signifies we are no longer operating on a netmap fully loaded from
cache, even if most of the netmap is still in the same configuration.

Updates #12542

Change-Id: I84132c4bf2dde6e5c1c57144645edb986b051dca
Signed-off-by: M. J. Fromberger <fromberger@tailscale.com>
This commit is contained in:
M. J. Fromberger
2026-06-12 09:05:12 -07:00
committed by GitHub
parent 0108fb73a9
commit b23089a5ef

View File

@@ -3941,6 +3941,10 @@ func (c *Conn) UpdateNetmapDelta(muts []netmap.NodeMutation) {
ep.mu.Unlock()
}
}
// As of 2026-06-11 we will only get deltas from the control plane, so upon
// receiving one we should infer we have switched out of the cached state.
c.usingCachedNetmap.Store(false)
}
// UpdateStatus implements the interface needed by ipnstate.StatusBuilder.