tools/systemd/tm_editor: remove reset_time from add_days and document it

we never passed 'false' to it anyway so remove it
(we can add it again if we should ever need it)

also remove the adding of wday (gets normalized anyway)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak authored and Dietmar Maurer committed 2020-09-04 15:28:24 +02:00
1 parent 15ec790a40
commit 07ca6f6e66
2 files changed
+8 -10

No files matched your search

+3 -3
View File
@@ -181,10 +181,10 @@ pub fn compute_next_event(
.find(|d| event.days.contains(WeekDays::from_bits(1<<d).unwrap()))
{
// try next day
t.add_days(n - day_num, true)?;
t.add_days(n - day_num,)?;
} else {
// try next week
t.add_days(7 - day_num, true)?;
t.add_days(7 - day_num)?;
}
continue;
}
@@ -199,7 +199,7 @@ pub fn compute_next_event(
t.set_time(n as libc::c_int, 0, 0)?;
} else {
// test next day
t.add_days(1, true)?;
t.add_days(1)?;
}
continue;
}