android_kernel_motorola_sm6225/security
Dan Carpenter 5430209497 Smack: freeing an error pointer in smk_write_revoke_subj()
This code used to rely on the fact that kfree(NULL) was a no-op, but
then we changed smk_parse_smack() to return error pointers on failure
instead of NULL.  Calling kfree() on an error pointer will oops.

I have re-arranged things a bit so that we only free things if they
have been allocated.

Fixes: e774ad683f ('smack: pass error code through pointers')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
2015-06-12 11:59:11 -07:00
..
apparmor LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00
integrity VFS: security/: d_backing_inode() annotations 2015-04-15 15:06:56 -04:00
keys switch keyctl_instantiate_key_common() to iov_iter 2015-04-11 22:27:12 -04:00
selinux LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00
smack Smack: freeing an error pointer in smk_write_revoke_subj() 2015-06-12 11:59:11 -07:00
tomoyo LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00
yama LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00
commoncap.c LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00
device_cgroup.c cgroup: rename cgroup_subsys->base_cftypes to ->legacy_cftypes 2014-07-15 11:05:09 -04:00
inode.c VFS: security/: d_inode() annotations 2015-04-15 15:06:57 -04:00
Kconfig kernel: conditionally support non-root users, groups and capabilities 2015-04-15 16:35:22 -07:00
lsm_audit.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2015-04-26 17:22:07 -07:00
Makefile LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00
min_addr.c mmap_min_addr check CAP_SYS_RAWIO only for write 2010-04-23 08:56:31 +10:00
security.c LSM: Switch to lists of hooks 2015-05-12 15:00:41 +10:00