Commit fe5e418c authored by nixiaoming's avatar nixiaoming Committed by Greg Kroah-Hartman
Browse files

selinux: cleanup dentry and inodes on error in selinuxfs



[ Upstream commit 7e4237fa ]

If the resource requested by d_alloc_name is not added to the linked
list through d_add, then dput needs to be called to release the
subsequent abnormal branch to avoid resource leakage.

Add missing dput to selinuxfs.c

Signed-off-by: default avatarnixiaoming <nixiaoming@huawei.com>
[PM: tweak the subject line]
Signed-off-by: default avatarPaul Moore <paul@paul-moore.com>
Signed-off-by: default avatarSasha Levin <alexander.levin@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c3fb1a35
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment