diff options
author | Alex Auvolat <alex@adnab.me> | 2023-01-26 16:20:41 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2023-01-26 16:20:41 +0100 |
commit | 94d559ae00bdb899c4463667a9d950b27e5bb23c (patch) | |
tree | a734a4d05cbedfaaff4f3bf63a0b659499b797bb /src/util/time.rs | |
parent | c7d0ad0aa0e492b913c5dda8ff1a7ad5a579fb3a (diff) | |
parent | 5fb383fe4c248181e27df12a57849886e50bacb7 (diff) | |
download | garage-94d559ae00bdb899c4463667a9d950b27e5bb23c.tar.gz garage-94d559ae00bdb899c4463667a9d950b27e5bb23c.zip |
Merge branch 'main' into report-disk-usage
Diffstat (limited to 'src/util/time.rs')
-rw-r--r-- | src/util/time.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util/time.rs b/src/util/time.rs index 257b4d2a..42f41a44 100644 --- a/src/util/time.rs +++ b/src/util/time.rs @@ -25,6 +25,6 @@ pub fn increment_logical_clock_2(prev: u64, prev2: u64) -> u64 { pub fn msec_to_rfc3339(msecs: u64) -> String { let secs = msecs as i64 / 1000; let nanos = (msecs as i64 % 1000) as u32 * 1_000_000; - let timestamp = Utc.timestamp(secs, nanos); + let timestamp = Utc.timestamp_opt(secs, nanos).unwrap(); timestamp.to_rfc3339_opts(SecondsFormat::Millis, true) } |