Fixed time-related metadata.

geesefs-0-30-9
Aaron Jacobs 2015-03-03 10:48:26 +11:00
parent f9e2e55ac8
commit 420fcddfac
3 changed files with 7 additions and 4 deletions

View File

@ -159,10 +159,11 @@ type InodeAttributes struct {
Size uint64
Mode os.FileMode
// Time information
Atime time.Time
Mtime time.Time
Crtime time.Time
// Time information. See `man 2 stat` for full details.
Atime time.Time // Time of last access
Mtime time.Time // Time of last modification
Ctime time.Time // Time of last modification to inode
Crtime time.Time // Time of creation (OS X only)
// Owner information
Uid uint32

View File

@ -247,6 +247,7 @@ func (fs *memFS) MkDir(
Mode: req.Mode,
Atime: now,
Mtime: now,
Ctime: now,
Crtime: now,
}

View File

@ -288,6 +288,7 @@ func convertAttributes(inode InodeID, attr InodeAttributes) bazilfuse.Attr {
Mode: attr.Mode,
Atime: attr.Atime,
Mtime: attr.Mtime,
Ctime: attr.Ctime,
Crtime: attr.Crtime,
Uid: attr.Uid,
Gid: attr.Gid,