croncpp icon indicating copy to clipboard operation
croncpp copied to clipboard

Daylight saving issue

Open Edgaras-Randis opened this issue 6 years ago • 1 comments

unix epoch time: 1585398600 Saturday, March 28, 2020 2:30:00 PM GMT+02:00

rule: 0 30 14 * * *

using that time, next time returns the same time, it's probably related with the daylight time saving of next day change.

Edgaras-Randis avatar Apr 24 '19 13:04 Edgaras-Randis

This code fails:

time_t now = 1585398600;    // Saturday, March 28, 2020 2:30:00 PM GMT+02:00
std::string expr = "0 30 14 * * *";
cron::cronexpr exp = cron::make_cron(expr);
time_t next = cron::cron_next(exp, now);

REQUIRE(next > now);

mariusbancila avatar May 02 '22 20:05 mariusbancila