57586fdfa4
@monthly jobs would run hearly without this patch, and @hourly jobs would run only every second hour if the system is in DST.
23 lines
862 B
Diff
23 lines
862 B
Diff
diff --git a/database.c b/database.c
|
|
--- a/database.c
|
|
+++ b/database.c
|
|
@@ -410,6 +410,7 @@ SynchronizeFile(const char *dpath, const char *fileName, const char *userName)
|
|
break;
|
|
case 5:
|
|
line.cl_Freq = MONTHLY_FREQ;
|
|
+ break;
|
|
case 6:
|
|
line.cl_Freq = YEARLY_FREQ;
|
|
/* else line.cl_Freq will remain 0 */
|
|
diff --git a/database.c b/database.c
|
|
--- a/database.c
|
|
+++ b/database.c
|
|
@@ -258,6 +258,7 @@ ReadTimestamps(const char *user)
|
|
if (ptr && (*ptr == 0 || *ptr == '\n'))
|
|
/* strptime uses current seconds when seconds not specified? anyway, we don't get round minutes */
|
|
tm.tm_sec = 0;
|
|
+ tm.tm_isdst = -1;
|
|
sec = mktime(&tm);
|
|
if (sec == (time_t)-1) {
|
|
printlogf(LOG_ERR, "failed parsing timestamp for user %s job %s\n", file->cf_UserName, line->cl_JobName);
|