mirror of
https://git.proxmox.com/git/proxmox
synced 2025-08-05 15:06:16 +00:00
proxmox/src/tools/time.rs: fix previous commit
This commit is contained in:
parent
5eb5b21044
commit
fb4e426a0a
@ -1,4 +1,5 @@
|
||||
use anyhow::{bail, Error};
|
||||
use std::ffi::{CStr, CString};
|
||||
|
||||
/// Safe bindings to libc timelocal
|
||||
///
|
||||
@ -118,6 +119,6 @@ pub fn strftime(format: &str, t: &libc::tm) -> Result<String, Error> {
|
||||
|
||||
/// Convert Unix epoch into RFC3339 UTC string
|
||||
pub fn epoch_to_rfc_3339_utc(epoch: i64) -> Result<String, Error> {
|
||||
let gmtime = proxmox::tools::time::gmtime(epoch)?;
|
||||
let gmtime = gmtime(epoch)?;
|
||||
strftime("%FT%TZ", &gmtime)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user