ndisc: make first solicit delayed randomly
authorYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 6 Sep 2019 18:36:19 +0000 (03:36 +0900)
committerMichael Biebl <biebl@debian.org>
Fri, 15 Nov 2019 21:01:17 +0000 (21:01 +0000)
Closes #13460.

(cherry picked from commit 9973e6c43abb9d3d73fcfee83c886dbd32e700ca)
(cherry picked from commit ccf797511e0af237d67a6a5511e760bd41de1732)

Gbp-Pq: Name ndisc-make-first-solicit-delayed-randomly.patch

src/libsystemd-network/sd-ndisc.c

index 5e711713d9d5596f6421d9a550e35429b3996f29..9922203ac4be88002c91d7e2ca06eb344b925634 100644 (file)
@@ -365,7 +365,7 @@ _public_ int sd_ndisc_start(sd_ndisc *nd) {
 
         r = event_reset_time(nd->event, &nd->timeout_event_source,
                              clock_boottime_or_monotonic(),
-                             0, 0,
+                             time_now + USEC_PER_SEC / 2, 1 * USEC_PER_SEC, /* See RFC 8415 sec. 18.2.1 */
                              ndisc_timeout, nd,
                              nd->event_priority, "ndisc-timeout", true);
         if (r < 0)