File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed
Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -526,15 +526,11 @@ lease_next(void)
526526 if (n < 0 ) {
527527 e .expire = -1 ; // unlimited
528528 } else {
529- // If n looks like a relative duration (< ~3 years in seconds), treat as relative
530- // This happens if dnsmasq has the HAVE_BROKEN_RTC flag set
531- int relative_expire = (n > 0 && n < 100000000 );
532-
533- if (relative_expire ) {
534- // n is a relative duration in seconds
529+ if (L .hasSystemFeature ('dnsmasq' , 'rtc' )) {
530+ // If RTC is disabled, n is a relative duration in seconds
535531 e .expire = n ; // already relative, pass through as-is
536532 } else {
537- // n is an absolute timestamp
533+ // If hardware times are trusted, n is an absolute timestamp
538534 if (n > lease_state .now )
539535 e .expire = n - lease_state .now ;
540536 else if (n >= 0 )
You can’t perform that action at this time.
0 commit comments