projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
i2c: rcar: simplify check for last message
[firefly-linux-kernel-4.4.55.git]
/
mm
/
shmem.c
diff --git
a/mm/shmem.c
b/mm/shmem.c
index 0e5fb225007c519a27b680673160011bd74dd445..469f90d56051984c674f395042029ea737608d5b 100644
(file)
--- a/
mm/shmem.c
+++ b/
mm/shmem.c
@@
-2367,8
+2367,10
@@
static int shmem_rename2(struct inode *old_dir, struct dentry *old_dentry, struc
if (new_dentry->d_inode) {
(void) shmem_unlink(new_dir, new_dentry);
- if (they_are_dirs)
+ if (they_are_dirs) {
+ drop_nlink(new_dentry->d_inode);
drop_nlink(old_dir);
+ }
} else if (they_are_dirs) {
drop_nlink(old_dir);
inc_nlink(new_dir);