Skip to content

Commit

Permalink
fuse: fix attribute caching after rename
Browse files Browse the repository at this point in the history
Invalidate attributes on rename, since some filesystems may update
st_ctime.  Reported by Szabolcs Szakacsits

Signed-off-by: Miklos Szeredi <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
szmi authored and Linus Torvalds committed Nov 29, 2007
1 parent fbee36b commit 08b6330
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions fs/fuse/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -657,6 +657,9 @@ static int fuse_rename(struct inode *olddir, struct dentry *oldent,
err = req->out.h.error;
fuse_put_request(fc, req);
if (!err) {
/* ctime changes */
fuse_invalidate_attr(oldent->d_inode);

fuse_invalidate_attr(olddir);
if (olddir != newdir)
fuse_invalidate_attr(newdir);
Expand Down

0 comments on commit 08b6330

Please sign in to comment.