@@ -20,7 +20,7 @@ type Connection struct {
20
20
broadcastChan chan Message
21
21
hosts * xsync.MapOf [string , string ]
22
22
services * xsync.MapOf [string , string ]
23
- routes * * xsync.MapOf [string , string ]
23
+ routes * * * xsync.MapOf [string , string ]
24
24
iface string
25
25
}
26
26
@@ -30,7 +30,7 @@ func HandleConnection(
30
30
broadcastChan chan Message ,
31
31
hosts * xsync.MapOf [string , string ],
32
32
services * xsync.MapOf [string , string ],
33
- routes * * xsync.MapOf [string , string ],
33
+ routes * * * xsync.MapOf [string , string ],
34
34
) {
35
35
// conn.RemoteAddr().String() should be in the format [fe80::ac1e:2c4%wgc32]:38428
36
36
// where wgc32 is the interface name
@@ -205,8 +205,8 @@ func (c *Connection) start() {
205
205
}
206
206
207
207
func (c * Connection ) validNextHop (cmd Command , srcIP net.IP ) bool {
208
- route , hasRoute := (* c .routes ).Load (srcIP .String ())
209
- slog .Info ("routes" , "routes" , c .routes )
208
+ route , hasRoute := (* * c .routes ).Load (srcIP .String ())
209
+ slog .Info ("routes" , "routes" , * c .routes )
210
210
slog .Info ("arednlink: valid next hop" , "command" , cmd , "source" , srcIP , "route" , route , "hasRoute" , hasRoute , "myiface" , c .iface , "myip" , net .ParseIP (c .config .NodeIP ))
211
211
if srcIP != nil && ! srcIP .Equal (net .ParseIP (c .config .NodeIP )) && (cmd == CommandSync || (hasRoute && route == c .iface )) {
212
212
return true
0 commit comments