X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Fgraph.c;h=8e39b98d62f7e0c0167ad36b4fa697c2e7864cd2;hb=cb8aedb0d1da7fc93299d8fd5005b9631364b7ee;hp=9b0184b091a0cdf15602871afcb7f5e277614720;hpb=f712fdc0b3de22566cdf06954256c62f46f25542;p=meshlink diff --git a/src/graph.c b/src/graph.c index 9b0184b0..8e39b98d 100644 --- a/src/graph.c +++ b/src/graph.c @@ -229,16 +229,21 @@ static void check_reachability(meshlink_handle_t *mesh) { timeout_del(&mesh->loop, &n->mtutimeout); - update_node_status(mesh, n); + if(!n->status.blacklisted) { + update_node_status(mesh, n); + } if(!n->status.reachable) { update_node_udp(mesh, n, NULL); n->status.broadcast = false; n->options = 0; + utcp_offline(n->utcp, true); } else if(n->connection) { if(n->connection->outgoing) { send_req_key(mesh, n); } + + utcp_offline(n->utcp, false); } } }