summaryrefslogtreecommitdiffstats
path: root/nhrpd/nhrp_nhs.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-08-05 09:56:23 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-08-05 09:56:23 +0000
commitc15d6efd40655f717841d00839a43df1ead5cb26 (patch)
tree35d579f9a19170e2b39085669ca92533c2d161b4 /nhrpd/nhrp_nhs.c
parentAdding upstream version 10.0.1. (diff)
downloadfrr-c15d6efd40655f717841d00839a43df1ead5cb26.tar.xz
frr-c15d6efd40655f717841d00839a43df1ead5cb26.zip
Adding upstream version 10.1.upstream/10.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'nhrpd/nhrp_nhs.c')
-rw-r--r--nhrpd/nhrp_nhs.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/nhrpd/nhrp_nhs.c b/nhrpd/nhrp_nhs.c
index acd3b7d..f779f93 100644
--- a/nhrpd/nhrp_nhs.c
+++ b/nhrpd/nhrp_nhs.c
@@ -169,9 +169,15 @@ static void nhrp_reg_send_req(struct event *t)
struct nhrp_cie_header *cie;
if (!nhrp_peer_check(r->peer, 2)) {
- debugf(NHRP_DEBUG_COMMON, "NHS: Waiting link for %pSU",
- &r->peer->vc->remote.nbma);
- event_add_timer(master, nhrp_reg_send_req, r, 120,
+ int renewtime = if_ad->holdtime / 4;
+ /* RFC 2332 5.2.0.1 says "a retry is sent after an appropriate
+ * interval." Using holdtime/4, to be shorter than
+ * recommended renew time (holdtime/3), see RFC2332 Sec 5.2.3
+ */
+ debugf(NHRP_DEBUG_COMMON,
+ "NHS: Waiting link for %pSU, retrying in %d seconds",
+ &r->peer->vc->remote.nbma, renewtime);
+ event_add_timer(master, nhrp_reg_send_req, r, renewtime,
&r->t_register);
return;
}