aboutsummaryrefslogtreecommitdiffstats
path: root/fs/hfs/dir.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/hfs/dir.c')
-rw-r--r--fs/hfs/dir.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/hfs/dir.c b/fs/hfs/dir.c
index 616cfe02b601..1cb70cdba2c1 100644
--- a/fs/hfs/dir.c
+++ b/fs/hfs/dir.c
@@ -286,6 +286,9 @@ static int hfs_rename(struct inode *old_dir, struct dentry *old_dentry,
286 286
287 /* Unlink destination if it already exists */ 287 /* Unlink destination if it already exists */
288 if (new_dentry->d_inode) { 288 if (new_dentry->d_inode) {
289 if (S_ISDIR(new_dentry->d_inode->i_mode))
290 dentry_unhash(new_dentry);
291
289 res = hfs_remove(new_dir, new_dentry); 292 res = hfs_remove(new_dir, new_dentry);
290 if (res) 293 if (res)
291 return res; 294 return res;