mirror of
https://github.com/tailscale/tailscale.git
synced 2025-10-25 18:20:07 +00:00
tstest/natlab/vnet: rename some things for clarity
The bad naming (which had only been half updated with the IPv6 changes) tripped me up in the earlier change. Updates #13038 Change-Id: I65ce07c167e8219d35b87e1f4bf61aab4cac31ff Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
committed by
Brad Fitzpatrick
parent
0157000cab
commit
f99f970dc1
@@ -328,7 +328,7 @@ func (s *Server) initFromConfig(c *Config) error {
|
||||
v6: conf.wanIP6.IsValid(),
|
||||
wanIP4: conf.wanIP4,
|
||||
lanIP4: conf.lanIP4,
|
||||
nodesByIP: map[netip.Addr]*node{},
|
||||
nodesByIP4: map[netip.Addr]*node{},
|
||||
nodesByMAC: map[MAC]*node{},
|
||||
logf: logger.WithPrefix(log.Printf, fmt.Sprintf("[net-%v] ", conf.mac)),
|
||||
}
|
||||
@@ -389,7 +389,7 @@ func (s *Server) initFromConfig(c *Config) error {
|
||||
ip4 := n.net.lanIP4.Addr().As4()
|
||||
ip4[3] = 100 + n.mac[5]
|
||||
n.lanIP = netip.AddrFrom4(ip4)
|
||||
n.net.nodesByIP[n.lanIP] = n
|
||||
n.net.nodesByIP4[n.lanIP] = n
|
||||
}
|
||||
n.net.nodesByMAC[n.mac] = n
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user