[PATCH] selinux: kfree cleanup
kfree(NULL) is legal. Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk> Acked-by: Stephen Smalley <sds@tycho.nsa.gov> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
a2ba192c96
commit
9a5f04bf79
@@ -1658,9 +1658,8 @@ static int selinux_bprm_secureexec (struct linux_binprm *bprm)
|
||||
|
||||
static void selinux_bprm_free_security(struct linux_binprm *bprm)
|
||||
{
|
||||
struct bprm_security_struct *bsec = bprm->security;
|
||||
kfree(bprm->security);
|
||||
bprm->security = NULL;
|
||||
kfree(bsec);
|
||||
}
|
||||
|
||||
extern struct vfsmount *selinuxfs_mount;
|
||||
|
Reference in New Issue
Block a user