mirror of
https://github.com/tailscale/tailscale.git
synced 2026-07-18 11:32:04 -04:00
[This commit is pulled out of a branch that ultimately removes the wgcfg.Config.Peers field and removes all O(n peers) processing when handling deltas] magicsock.Conn.UpdatePeers existed so wgengine.Reconfig could tell magicsock the set of WireGuard peers from cfg.Peers, used only to garbage collect the derpRoute and peerLastDerp maps and to ReSTUN when the first peers appear. magicsock already learns the full peer list directly from LocalBackend via SetNetworkMap, UpsertPeer, and RemovePeer, so do that bookkeeping there and delete the API and its cfg.Peers use. Updates #12542 Change-Id: Id07551fc1950239f08a73a9ab02d69ce78d0de0c Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>