Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 252715
b: refs/heads/master
c: 8aaa0f5
h: refs/heads/master
i:
  252713: 64ec4e4
  252711: 85a3bfa
v: v3
  • Loading branch information
Sage Weil authored and Al Viro committed May 28, 2011
1 parent a3b4b36 commit 69b2484
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 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: 7020739df2fa0e2126fc9739987e016860f14323
refs/heads/master: 8aaa0f5431d8d1181b3d1a1bcd8f3330c0ce275f
11 changes: 3 additions & 8 deletions trunk/fs/omfs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -241,11 +241,9 @@ static int omfs_remove(struct inode *dir, struct dentry *dentry)
int ret;


if (S_ISDIR(inode->i_mode)) {
dentry_unhash(dentry);
if (!omfs_dir_is_empty(inode))
return -ENOTEMPTY;
}
if (S_ISDIR(inode->i_mode) &&
!omfs_dir_is_empty(inode))
return -ENOTEMPTY;

ret = omfs_delete_entry(dentry);
if (ret)
Expand Down Expand Up @@ -382,9 +380,6 @@ static int omfs_rename(struct inode *old_dir, struct dentry *old_dentry,
int err;

if (new_inode) {
if (S_ISDIR(new_inode->i_mode))
dentry_unhash(new_dentry);

/* overwriting existing file/dir */
err = omfs_remove(new_dir, new_dentry);
if (err)
Expand Down

0 comments on commit 69b2484

Please sign in to comment.