projects
/
platform
/
kernel
/
linux-exynos.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9c312e7
)
selinux: Return directly after a failed kzalloc() in cat_read()
author
Markus Elfring
<elfring@users.sourceforge.net>
Sat, 14 Jan 2017 20:20:43 +0000
(21:20 +0100)
committer
Paul Moore
<paul@paul-moore.com>
Wed, 29 Mar 2017 13:54:48 +0000
(09:54 -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
a838939
..
36285d1
100644
(file)
--- a/
security/selinux/ss/policydb.c
+++ b/
security/selinux/ss/policydb.c
@@
-1637,10
+1637,9
@@
static int cat_read(struct policydb *p, struct hashtab *h, void *fp)
__le32 buf[3];
u32 len;
- rc = -ENOMEM;
catdatum = kzalloc(sizeof(*catdatum), GFP_ATOMIC);
if (!catdatum)
-
goto bad
;
+
return -ENOMEM
;
rc = next_entry(buf, fp, sizeof buf);
if (rc)