diff options
author | 2005-10-26 12:53:25 +0000 | |
---|---|---|
committer | 2005-10-26 12:53:25 +0000 | |
commit | b0b13d1e5499e20382ad74e202160d49e1792ee8 (patch) | |
tree | 77c9dbbceda8149929fed4e66411b49a405808cf /lib/fuse_lowlevel.c | |
parent | c4c12ae295ca6f3fb02e12d3bad8f92fee4dfe3f (diff) |
add access operation
Diffstat (limited to 'lib/fuse_lowlevel.c')
-rw-r--r-- | lib/fuse_lowlevel.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c index 95882ed..22dc41d 100644 --- a/lib/fuse_lowlevel.c +++ b/lib/fuse_lowlevel.c @@ -69,6 +69,7 @@ static const char *opname(enum fuse_opcode opcode) case FUSE_READDIR: return "READDIR"; case FUSE_RELEASEDIR: return "RELEASEDIR"; case FUSE_FSYNCDIR: return "FSYNCDIR"; + case FUSE_ACCESS: return "ACCESS"; default: return "???"; } } @@ -361,6 +362,15 @@ static void do_setattr(fuse_req_t req, fuse_ino_t nodeid, fuse_reply_err(req, ENOSYS); } +static void do_access(fuse_req_t req, fuse_ino_t nodeid, + struct fuse_access_in *arg) +{ + if (req->f->op.access) + req->f->op.access(req, nodeid, arg->mask); + else + fuse_reply_err(req, ENOSYS); +} + static void do_readlink(fuse_req_t req, fuse_ino_t nodeid) { if (req->f->op.readlink) @@ -811,6 +821,10 @@ static void fuse_ll_process(void *data, const char *buf, size_t len, do_fsyncdir(req, in->nodeid, (struct fuse_fsync_in *) inarg); break; + case FUSE_ACCESS: + do_access(req, in->nodeid, (struct fuse_access_in *) inarg); + break; + default: fuse_reply_err(req, ENOSYS); } |