]> git.meshlink.io Git - meshlink/blobdiff - src/graph.c
When resetting timers that use CLOCK_MONOTONIC, use a negative value.
[meshlink] / src / graph.c
index b0e0b77a198a408cd2d88aecb2c4debde09022d3..050acbf5f4d45f0c375c5a077b139ccf9c1290b7 100644 (file)
@@ -158,7 +158,7 @@ static void check_reachability(meshlink_handle_t *mesh) {
                                n->status.validkey = false;
                                sptps_stop(&n->sptps);
                                n->status.waitingforkey = false;
-                               n->last_req_key = 0;
+                               n->last_req_key = -3600;
 
                                n->status.udp_confirmed = false;
                                n->maxmtu = MTU;
@@ -196,7 +196,7 @@ static void check_reachability(meshlink_handle_t *mesh) {
                        n->status.validkey = false;
                        sptps_stop(&n->sptps);
                        n->status.waitingforkey = false;
-                       n->last_req_key = 0;
+                       n->last_req_key = -3600;
 
                        n->status.udp_confirmed = false;
                        n->maxmtu = MTU;