projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
442ca4d
)
selinux: Return directly after a failed kzalloc() in perm_read()
author
Markus Elfring
<elfring@users.sourceforge.net>
Sun, 15 Jan 2017 10:20:13 +0000
(11:20 +0100)
committer
Paul Moore
<paul@paul-moore.com>
Wed, 29 Mar 2017 15:30:51 +0000
(11:30 -0400)
Return directly after a call of the function "kzalloc" failed
at the beginning.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Paul Moore <paul@paul-moore.com>
security/selinux/ss/policydb.c
patch
|
blob
|
history
diff --git
a/security/selinux/ss/policydb.c
b/security/selinux/ss/policydb.c
index 99ee0ee2d92afd256243a3250ac24c65e474a853..5ca2d26ecf7fe4df31832b20d2525adf6d393ec9 100644
(file)
--- a/
security/selinux/ss/policydb.c
+++ b/
security/selinux/ss/policydb.c
@@
-1118,10
+1118,9
@@
static int perm_read(struct policydb *p, struct hashtab *h, void *fp)
__le32 buf[2];
u32 len;
- rc = -ENOMEM;
perdatum = kzalloc(sizeof(*perdatum), GFP_KERNEL);
if (!perdatum)
-
goto bad
;
+
return -ENOMEM
;
rc = next_entry(buf, fp, sizeof buf);
if (rc)