Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 139542
b: refs/heads/master
c: b1e4adf
h: refs/heads/master
v: v3
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed Mar 19, 2009
1 parent 7ff2b7e commit 2f688e9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 47c62564200609b6de60f535f61f0c73dd10c7c9
refs/heads/master: b1e4adf4ea41bb8b5a7bfc1a7001f137e65495df
9 changes: 4 additions & 5 deletions trunk/fs/nfs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -1624,8 +1624,7 @@ static int nfs_rename(struct inode *old_dir, struct dentry *old_dentry,
} else if (atomic_read(&new_dentry->d_count) > 1)
/* dentry still busy? */
goto out;
} else
nfs_drop_nlink(new_inode);
}

go_ahead:
/*
Expand All @@ -1638,10 +1637,8 @@ static int nfs_rename(struct inode *old_dir, struct dentry *old_dentry,
}
nfs_inode_return_delegation(old_inode);

if (new_inode != NULL) {
if (new_inode != NULL)
nfs_inode_return_delegation(new_inode);
d_delete(new_dentry);
}

error = NFS_PROTO(old_dir)->rename(old_dir, &old_dentry->d_name,
new_dir, &new_dentry->d_name);
Expand All @@ -1650,6 +1647,8 @@ static int nfs_rename(struct inode *old_dir, struct dentry *old_dentry,
if (rehash)
d_rehash(rehash);
if (!error) {
if (new_inode != NULL)
nfs_drop_nlink(new_inode);
d_move(old_dentry, new_dentry);
nfs_set_verifier(new_dentry,
nfs_save_change_attribute(new_dir));
Expand Down

0 comments on commit 2f688e9

Please sign in to comment.