diff options
author | Matthew Heon <matthew.heon@gmail.com> | 2018-02-12 14:58:24 -0500 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-02-13 15:39:07 +0000 |
commit | 35e1ad78fbab93f9efcf5f6608e5bc5569277845 (patch) | |
tree | 063283cafad3d3687a4475309807508e0ad3480a /libpod/finished_64.go | |
parent | 3d0100bb44834d079ad0e2c7b9c264a3c5ec131e (diff) | |
download | podman-35e1ad78fbab93f9efcf5f6608e5bc5569277845.tar.gz podman-35e1ad78fbab93f9efcf5f6608e5bc5569277845.tar.bz2 podman-35e1ad78fbab93f9efcf5f6608e5bc5569277845.zip |
Make libpod build on 32-bit systems
Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
Closes: #324
Approved by: rhatdan
Diffstat (limited to 'libpod/finished_64.go')
-rw-r--r-- | libpod/finished_64.go | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/libpod/finished_64.go b/libpod/finished_64.go new file mode 100644 index 000000000..11dbc9181 --- /dev/null +++ b/libpod/finished_64.go @@ -0,0 +1,16 @@ +// +build !arm,!386 + +package libpod + +import ( + "os" + "syscall" + "time" +) + +// Get the created time of a file +// Only works on 64-bit OSes +func getFinishedTime(fi os.FileInfo) time.Time { + st := fi.Sys().(*syscall.Stat_t) + return time.Unix(st.Ctim.Sec, st.Ctim.Nsec) +} |