Merge "Allow updates for open file descriptors"

This commit is contained in:
Marco Nelissen 2014-12-10 18:50:08 +00:00 committed by Gerrit Code Review
commit 5eb431180b
1 changed files with 3 additions and 1 deletions

View File

@ -904,7 +904,9 @@ static int handle_setattr(struct fuse* fuse, struct fuse_handler* handler,
if (!node) {
return -ENOENT;
}
if (!check_caller_access_to_node(fuse, hdr, node, W_OK, has_rw)) {
if (!(req->valid & FATTR_FH) &&
!check_caller_access_to_node(fuse, hdr, node, W_OK, has_rw)) {
return -EACCES;
}