Commit 36c07875 authored by Anand Avati's avatar Anand Avati Committed by Ben Hutchings

fuse: invalidate inode attributes on xattr modification

commit d331a415 upstream.

Calls like setxattr and removexattr result in updation of ctime.
Therefore invalidate inode attributes to force a refresh.
Signed-off-by: default avatarAnand Avati <avati@redhat.com>
Reviewed-by: default avatarBrian Foster <bfoster@redhat.com>
Signed-off-by: default avatarMiklos Szeredi <mszeredi@suse.cz>
Signed-off-by: default avatarBen Hutchings <ben@decadent.org.uk>
parent e68a3e37
...@@ -1439,6 +1439,8 @@ static int fuse_setxattr(struct dentry *entry, const char *name, ...@@ -1439,6 +1439,8 @@ static int fuse_setxattr(struct dentry *entry, const char *name,
fc->no_setxattr = 1; fc->no_setxattr = 1;
err = -EOPNOTSUPP; err = -EOPNOTSUPP;
} }
if (!err)
fuse_invalidate_attr(inode);
return err; return err;
} }
...@@ -1568,6 +1570,8 @@ static int fuse_removexattr(struct dentry *entry, const char *name) ...@@ -1568,6 +1570,8 @@ static int fuse_removexattr(struct dentry *entry, const char *name)
fc->no_removexattr = 1; fc->no_removexattr = 1;
err = -EOPNOTSUPP; err = -EOPNOTSUPP;
} }
if (!err)
fuse_invalidate_attr(inode);
return err; return err;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment