Skip to content
Snippets Groups Projects
Commit b8bc83ab authored by Tvrtko Ursulin's avatar Tvrtko Ursulin Committed by James Morris
Browse files

securityfs: Drop dentry reference count when mknod fails


lookup_one_len increments dentry reference count which is not decremented
when the create operation fails. This can cause a kernel BUG at
fs/dcache.c:676 at unmount time. Also error code returned when new_inode()
fails was replaced with more appropriate -ENOMEM.

Signed-off-by: default avatarTvrtko Ursulin <tvrtko.ursulin@sophos.com>
Acked-by: default avatarSerge E. Hallyn <serge@hallyn.com>
Acked-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: default avatarJames Morris <jmorris@namei.org>
parent 57a62c23
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment