]> git.meshlink.io Git - meshlink/blobdiff - src/graph.c
Don't send UDP probes to tiny nodes.
[meshlink] / src / graph.c
index 9a2bfb191e77beb068ceb52477680761da96c94e..0179059d443bcf77dbbd276cd5fbb069f06340d7 100644 (file)
@@ -161,9 +161,8 @@ static void check_reachability(meshlink_handle_t *mesh) {
                        n->status.udp_confirmed = false;
                        n->maxmtu = MTU;
                        n->minmtu = 0;
+                       n->udpprobes = 0;
                        n->mtuprobes = 0;
-
-                       timeout_del(&mesh->loop, &n->mtutimeout);
                }
 
                if(n->status.visited != n->status.reachable) {
@@ -191,9 +190,10 @@ static void check_reachability(meshlink_handle_t *mesh) {
                        n->status.udp_confirmed = false;
                        n->maxmtu = MTU;
                        n->minmtu = 0;
+                       n->udpprobes = 0;
                        n->mtuprobes = 0;
 
-                       timeout_del(&mesh->loop, &n->mtutimeout);
+                       timeout_del(&mesh->loop, &n->udp_ping_timeout);
 
                        if(!n->status.blacklisted) {
                                update_node_status(mesh, n);