summaryrefslogtreecommitdiff
path: root/internal/fusefrontend_reverse/rfs.go
diff options
context:
space:
mode:
authorJakob Unterwurzacher2017-04-29 14:50:58 +0200
committerJakob Unterwurzacher2017-04-29 14:50:58 +0200
commitedb3e19cb5543c580261052395d461fa47c7cf58 (patch)
tree293271bda453e8120fe271d2d146a73d852b90ca /internal/fusefrontend_reverse/rfs.go
parent7d38f80a78644c8ec4900cc990bfb894387112ed (diff)
fix golint complaints
Diffstat (limited to 'internal/fusefrontend_reverse/rfs.go')
-rw-r--r--internal/fusefrontend_reverse/rfs.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/internal/fusefrontend_reverse/rfs.go b/internal/fusefrontend_reverse/rfs.go
index 3c52244..06bbfe9 100644
--- a/internal/fusefrontend_reverse/rfs.go
+++ b/internal/fusefrontend_reverse/rfs.go
@@ -182,13 +182,13 @@ func (rfs *ReverseFS) GetAttr(relPath string, context *fuse.Context) (*fuse.Attr
// Access - FUSE call
func (rfs *ReverseFS) Access(relPath string, mode uint32, context *fuse.Context) fuse.Status {
if rfs.isTranslatedConfig(relPath) || rfs.isDirIV(relPath) || rfs.isNameFile(relPath) {
+ // access(2) R_OK flag for checking if the file is readable, always 4 as defined in POSIX.
+ ROK := uint32(0x4)
// Virtual files can always be read and never written
- var R_OK uint32 = 4
- if mode == R_OK || mode == 0 {
+ if mode == ROK || mode == 0 {
return fuse.OK
- } else {
- return fuse.EPERM
}
+ return fuse.EPERM
}
absPath, err := rfs.abs(rfs.decryptPath(relPath))
if err != nil {