github.com/Prakhar-Agarwal-byte/moby@v0.0.0-20231027092010-a14e3e8ab87e/pkg/system/stat_bsd.go (about) 1 //go:build freebsd || netbsd 2 3 package system // import "github.com/Prakhar-Agarwal-byte/moby/pkg/system" 4 5 import "syscall" 6 7 // fromStatT converts a syscall.Stat_t type to a system.Stat_t type 8 func fromStatT(s *syscall.Stat_t) (*StatT, error) { 9 return &StatT{ 10 size: s.Size, 11 mode: uint32(s.Mode), 12 uid: s.Uid, 13 gid: s.Gid, 14 rdev: uint64(s.Rdev), 15 mtim: s.Mtimespec, 16 }, nil 17 }