1
0
Fork 0

nfsd: fix nfsdfs inode reference count leak

[ Upstream commit bf2654017e ]

I don't understand this code well, but  I'm seeing a warning about a
still-referenced inode on unmount, and every other similar filesystem
does a dput() here.

Fixes: e8a79fb14f ("nfsd: add nfsd/clients directory")
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
5.4-rM2-2.2.x-imx-squashed
J. Bruce Fields 2020-06-23 21:01:19 -04:00 committed by Greg Kroah-Hartman
parent 2571e17356
commit c84138b3c1
1 changed files with 1 additions and 0 deletions

View File

@ -1335,6 +1335,7 @@ void nfsd_client_rmdir(struct dentry *dentry)
WARN_ON_ONCE(ret);
fsnotify_rmdir(dir, dentry);
d_delete(dentry);
dput(dentry);
inode_unlock(dir);
}