diff options
| author | mrw1593 <botahamec@outlook.com> | 2022-03-07 09:56:46 -0500 |
|---|---|---|
| committer | mrw1593 <botahamec@outlook.com> | 2022-03-07 09:56:46 -0500 |
| commit | 43da205d0c486a082c380a1258229a055e5767ba (patch) | |
| tree | 2852943fb41316a47e9aa80c49a5282800c15574 /src/tai.rs | |
| parent | 0fb870509821eb6f8158a9ee3cc02e6a0f951c86 (diff) | |
Implemented proper second addition
Diffstat (limited to 'src/tai.rs')
| -rw-r--r-- | src/tai.rs | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -100,7 +100,8 @@ impl TimeZone for Tai { // keep checking until there is no longer a change in the total leap seconds while past_leap_seconds != prev_pls { prev_pls = past_leap_seconds; - let ndt = date_time.add_seconds(past_leap_seconds as isize); + // TODO think about this discard + let (ndt, _) = date_time.add_seconds_overflowing(past_leap_seconds as i64); let utc_dt = DateTime::from_utc(ndt, Utc); past_leap_seconds = leap_seconds.leap_seconds_before_inclusive(utc_dt); } |
