diff options
Diffstat (limited to 'fs/nfs/dir.c')
-rw-r--r-- | fs/nfs/dir.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index 76b7f539d76e..2c5ace4f00a7 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c | |||
@@ -1611,14 +1611,11 @@ static int nfs_rename(struct inode *old_dir, struct dentry *old_dentry, | |||
1611 | 1611 | ||
1612 | /* silly-rename the existing target ... */ | 1612 | /* silly-rename the existing target ... */ |
1613 | err = nfs_sillyrename(new_dir, new_dentry); | 1613 | err = nfs_sillyrename(new_dir, new_dentry); |
1614 | if (!err) { | 1614 | if (err) |
1615 | new_dentry = rehash = dentry; | ||
1616 | new_inode = NULL; | ||
1617 | /* instantiate the replacement target */ | ||
1618 | d_instantiate(new_dentry, NULL); | ||
1619 | } else if (atomic_read(&new_dentry->d_count) > 1) | ||
1620 | /* dentry still busy? */ | ||
1621 | goto out; | 1615 | goto out; |
1616 | |||
1617 | new_dentry = dentry; | ||
1618 | new_inode = NULL; | ||
1622 | } | 1619 | } |
1623 | } | 1620 | } |
1624 | 1621 | ||