mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
SELinux: remove redundant pointer checks before calling kfree()
We don't need to check for NULL pointers before calling kfree(). Signed-off-by: Paul Moore <[email protected]> Acked-by: Stephen Smalley <[email protected]> Signed-off-by: James Morris <[email protected]>
This commit is contained in:
parent
9534f71ca3
commit
088999e98b
1 changed files with 1 additions and 2 deletions
|
|
@ -4658,8 +4658,7 @@ static int selinux_secid_to_secctx(u32 secid, char **secdata, u32 *seclen)
|
|||
|
||||
static void selinux_release_secctx(char *secdata, u32 seclen)
|
||||
{
|
||||
if (secdata)
|
||||
kfree(secdata);
|
||||
kfree(secdata);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_KEYS
|
||||
|
|
|
|||
Loading…
Reference in a new issue