Files
splinter/src
lotherk 407f073ae3 delegate: a reset 292 billion years out is not a reset
"ready_at=9223372036854775807" in a provider's limit text was parsed with
strtol, stored as a cooldown and honoured: choose() then skipped that
delegate on every call and said nothing about it. On machine here that
would have wedged the delegate for good, from one unlucky answer.

A reset beyond LIMIT_MAX_AHEAD (370 days) is not a reset, so sp_limit_parse
drops it and the default one-hour bench applies. sp_cooldown_until does the
same with the file: it is plain text in a directory other runs can write,
so a value that is not a plausible time is not a bench either.

Test: tests/test_delegate.c feeds the absurd ready_at and asserts the bench
stays within two hours, a plausible ready_at is kept exactly, a cooldown
file holding LONG_MAX and a text line reads as no bench, and a real
sp_cooldown_set is still honoured. Red before the fix (until <= now + 2h,
sp_cooldown_until == 0), green after.
2026-11-23 10:23:17 +00:00
..