From: Guus Sliepen Date: Sat, 5 Sep 2020 09:52:12 +0000 (+0200) Subject: Use the fast retry period of the destination node's device class. X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=feebc141462741d5d0270245d7e97624ddd0bdf8;p=meshlink Use the fast retry period of the destination node's device class. --- diff --git a/src/net_socket.c b/src/net_socket.c index a6923139..7ac6dbbd 100644 --- a/src/net_socket.c +++ b/src/net_socket.c @@ -87,7 +87,7 @@ static void retry_outgoing_handler(event_loop_t *loop, void *data) { } void retry_outgoing(meshlink_handle_t *mesh, outgoing_t *outgoing) { - if(!mesh->reachable && mesh->loop.now.tv_sec < mesh->last_unreachable + mesh->dev_class_traits[mesh->devclass].fast_retry_period) { + if(!mesh->reachable && mesh->loop.now.tv_sec < mesh->last_unreachable + mesh->dev_class_traits[outgoing->node->devclass].fast_retry_period) { outgoing->timeout = 1; } else { outgoing->timeout += 5;