mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
Don't enforce limits on pings for LAN ips.
This commit is contained in:
parent
5e1d6f5183
commit
f07c588ef5
|
@ -1128,7 +1128,8 @@ static int handle_sendnodes_ipv6(void *object, IP_Port source, const uint8_t *pa
|
|||
uint32_t i;
|
||||
|
||||
for (i = 0; i < num_nodes; i++) {
|
||||
if (ipport_isset(&plain_nodes[i].ip_port) && ping_node_from_getnodes_ok(dht, plain_nodes[i].client_id)) {
|
||||
if (ipport_isset(&plain_nodes[i].ip_port) && (LAN_ip(plain_nodes[i].ip_port.ip) == 0
|
||||
|| ping_node_from_getnodes_ok(dht, plain_nodes[i].client_id))) {
|
||||
send_ping_request(dht->ping, plain_nodes[i].ip_port, plain_nodes[i].client_id);
|
||||
returnedip_ports(dht, plain_nodes[i].ip_port, plain_nodes[i].client_id, packet + 1);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user