mirror of
https://github.com/morgan9e/systemd
synced 2026-04-15 08:56:15 +09:00
dhcp6: do not use T1 and T2 longer than one provided by the lease
Fixes #12623.
This commit is contained in:
@@ -675,8 +675,7 @@ static int client_timeout_resend_expire(sd_event_source *s, uint64_t usec, void
|
||||
}
|
||||
|
||||
static usec_t client_timeout_compute_random(usec_t val) {
|
||||
return val - val / 10 +
|
||||
(random_u32() % (2 * USEC_PER_SEC)) * val / 10 / USEC_PER_SEC;
|
||||
return val - (random_u32() % USEC_PER_SEC) * val / 10 / USEC_PER_SEC;
|
||||
}
|
||||
|
||||
static int client_timeout_resend(sd_event_source *s, uint64_t usec, void *userdata) {
|
||||
|
||||
Reference in New Issue
Block a user