projects
/
wrapfs-3.4.y.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
86a8419
)
Wrapfs: drop our dentry in ->rmdir
author
Erez Zadok
<ezk@cs.sunysb.edu>
Fri, 9 Sep 2011 04:47:49 +0000
(
00:47
-0400)
committer
Erez Zadok
<ezk@cs.sunysb.edu>
Tue, 27 Dec 2016 03:11:34 +0000
(22:11 -0500)
Also clear nlinks on our inode.
Signed-off-by: Erez Zadok <ezk@cs.sunysb.edu>
fs/wrapfs/inode.c
patch
|
blob
|
history
diff --git
a/fs/wrapfs/inode.c
b/fs/wrapfs/inode.c
index 57786e1a62de9ba3434eaaa84e4e178d57bf7b0b..fc1cbb58b659473094bb2d5cdef7c4ca3647af7b 100644
(file)
--- a/
fs/wrapfs/inode.c
+++ b/
fs/wrapfs/inode.c
@@
-220,6
+220,9
@@
static int wrapfs_rmdir(struct inode *dir, struct dentry *dentry)
if (err)
goto out;
+ d_drop(dentry); /* drop our dentry on success (why not VFS's job?) */
+ if (dentry->d_inode)
+ clear_nlink(dentry->d_inode);
fsstack_copy_attr_times(dir, lower_dir_dentry->d_inode);
fsstack_copy_inode_size(dir, lower_dir_dentry->d_inode);
dir->i_nlink = lower_dir_dentry->d_inode->i_nlink;