aboutsummaryrefslogtreecommitdiff
path: root/weed/filesys/file.go
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2021-04-18 10:02:02 -0700
committerChris Lu <chris.lu@gmail.com>2021-04-18 10:02:02 -0700
commit54410ca955cf4078684bca17b4363dc33ef433ed (patch)
tree574495e4a30e6d83e35cbad61b1339fb0fd031de /weed/filesys/file.go
parentb0127645a59bf80e7746d3bf483ee4b5c34ba74f (diff)
downloadseaweedfs-54410ca955cf4078684bca17b4363dc33ef433ed.tar.xz
seaweedfs-54410ca955cf4078684bca17b4363dc33ef433ed.zip
cleaner way to set readonly
Diffstat (limited to 'weed/filesys/file.go')
-rw-r--r--weed/filesys/file.go12
1 files changed, 0 insertions, 12 deletions
diff --git a/weed/filesys/file.go b/weed/filesys/file.go
index 00a5ac279..2a991d7db 100644
--- a/weed/filesys/file.go
+++ b/weed/filesys/file.go
@@ -105,10 +105,6 @@ func (file *File) Open(ctx context.Context, req *fuse.OpenRequest, resp *fuse.Op
func (file *File) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *fuse.SetattrResponse) error {
- if file.wfs.option.ReadOnly {
- return fuse.EPERM
- }
-
glog.V(4).Infof("%v file setattr %+v", file.fullpath(), req)
entry, err := file.maybeLoadEntry(ctx)
@@ -197,10 +193,6 @@ func (file *File) Setattr(ctx context.Context, req *fuse.SetattrRequest, resp *f
func (file *File) Setxattr(ctx context.Context, req *fuse.SetxattrRequest) error {
- if file.wfs.option.ReadOnly {
- return fuse.EPERM
- }
-
glog.V(4).Infof("file Setxattr %s: %s", file.fullpath(), req.Name)
entry, err := file.maybeLoadEntry(ctx)
@@ -218,10 +210,6 @@ func (file *File) Setxattr(ctx context.Context, req *fuse.SetxattrRequest) error
func (file *File) Removexattr(ctx context.Context, req *fuse.RemovexattrRequest) error {
- if file.wfs.option.ReadOnly {
- return fuse.EPERM
- }
-
glog.V(4).Infof("file Removexattr %s: %s", file.fullpath(), req.Name)
entry, err := file.maybeLoadEntry(ctx)