aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchrislu <chris.lu@gmail.com>2022-02-12 22:41:29 -0800
committerchrislu <chris.lu@gmail.com>2022-02-12 22:41:29 -0800
commit4c75fd5f9c01af818894411e8a1e81dd2d5b1d20 (patch)
tree7253d77af7d25572f282c49b0adc58a64a6410c2
parentb0a5193e326962c8a411f872f45ddb6a16962fd9 (diff)
downloadseaweedfs-4c75fd5f9c01af818894411e8a1e81dd2d5b1d20.tar.xz
seaweedfs-4c75fd5f9c01af818894411e8a1e81dd2d5b1d20.zip
sync format
-rw-r--r--weed/mount/weedfs_attr.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/weed/mount/weedfs_attr.go b/weed/mount/weedfs_attr.go
index fddba289d..ba0b9a9ff 100644
--- a/weed/mount/weedfs_attr.go
+++ b/weed/mount/weedfs_attr.go
@@ -61,20 +61,20 @@ func (wfs *WFS) setRootAttr(out *fuse.AttrOut) {
func (wfs *WFS) setAttrByPbEntry(out *fuse.Attr, inode uint64, entry *filer_pb.Entry) {
out.Ino = inode
- out.Uid = entry.Attributes.Uid
- out.Gid = entry.Attributes.Gid
- out.Mode = toSystemMode(os.FileMode(entry.Attributes.FileMode))
+ out.Size = filer.FileSize(entry)
+ out.Blocks = (out.Size + blockSize - 1) / blockSize
+ setBlksize(out, blockSize)
out.Mtime = uint64(entry.Attributes.Mtime)
out.Ctime = uint64(entry.Attributes.Mtime)
out.Atime = uint64(entry.Attributes.Mtime)
+ out.Mode = toSystemMode(os.FileMode(entry.Attributes.FileMode))
if entry.HardLinkCounter > 0 {
out.Nlink = uint32(entry.HardLinkCounter)
} else {
out.Nlink = 1
}
- out.Size = filer.FileSize(entry)
- out.Blocks = (out.Size + blockSize - 1) / blockSize
- setBlksize(out, blockSize)
+ out.Uid = entry.Attributes.Uid
+ out.Gid = entry.Attributes.Gid
}
func (wfs *WFS) setAttrByFilerEntry(out *fuse.Attr, inode uint64, entry *filer.Entry) {