summaryrefslogtreecommitdiff
path: root/internal/fusefrontend/xattr.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/fusefrontend/xattr.go')
-rw-r--r--internal/fusefrontend/xattr.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/internal/fusefrontend/xattr.go b/internal/fusefrontend/xattr.go
index ac4b15f..813f286 100644
--- a/internal/fusefrontend/xattr.go
+++ b/internal/fusefrontend/xattr.go
@@ -48,13 +48,15 @@ func (fs *FS) GetXAttr(path string, attr string, context *fuse.Context) ([]byte,
return data, fuse.OK
}
+const _EOPNOTSUPP = fuse.Status(syscall.EOPNOTSUPP)
+
// SetXAttr implements pathfs.Filesystem.
func (fs *FS) SetXAttr(path string, attr string, data []byte, flags int, context *fuse.Context) fuse.Status {
if fs.isFiltered(path) {
return fuse.EPERM
}
if disallowedXAttrName(attr) {
- return fuse.EPERM
+ return _EOPNOTSUPP
}
flags = filterXattrSetFlags(flags)
@@ -74,7 +76,7 @@ func (fs *FS) RemoveXAttr(path string, attr string, context *fuse.Context) fuse.
return fuse.EPERM
}
if disallowedXAttrName(attr) {
- return fuse.EPERM
+ return _EOPNOTSUPP
}
cPath, err := fs.getBackingPath(path)
if err != nil {