BUG/MEDIUM: checks: make sure to always apply offsets to now_ms in expiration
authorWilly Tarreau <w@1wt.eu>
Fri, 15 Nov 2024 14:34:46 +0000 (15:34 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 15 Nov 2024 14:39:00 +0000 (15:39 +0100)
commit2f287f14f355e734e512732e35aebf993d000792
treec77d6be2ca280f0675ed218ad3a2a052e7ea0515
parent555994c96889966fa4dac6d9a444f4094778f593
BUG/MEDIUM: checks: make sure to always apply offsets to now_ms in expiration

Now_ms can be zero nowadays, so it's not suitable for direct assignment to
t->expire, as there's a risk that the timer never wakes up once assigned
(TICK_ETERNITY). Let's use tick_add(now_ms, 0) for an immediate wakeup
instead. The impact here might be health checks suddenly stopping.

This should be backported where it applies.
src/check.c
src/extcheck.c