diff options
author | Dan Carpenter <error27@gmail.com> | 2010-06-12 20:57:39 +0200 |
---|---|---|
committer | James Morris <jmorris@namei.org> | 2010-08-02 07:35:04 +0200 |
commit | 9a7982793c3aee6ce86d8e7e15306215257329f2 (patch) | |
tree | 4d85f6f7a57260cefd938dca7593aabf9c02a59c /security/selinux/ss | |
parent | selinux: fix error codes in cond_read_bool() (diff) | |
download | linux-9a7982793c3aee6ce86d8e7e15306215257329f2.tar.xz linux-9a7982793c3aee6ce86d8e7e15306215257329f2.zip |
selinux: fix error codes in symtab_init()
hashtab_create() only returns NULL on allocation failures to -ENOMEM is
appropriate here.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Eric Paris <eparis@redhat.com>
Acked-by: Stephen D. Smalley <sds@tycho.nsa.gov>
Signed-off-by: James Morris <jmorris@namei.org>
Diffstat (limited to 'security/selinux/ss')
-rw-r--r-- | security/selinux/ss/symtab.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/selinux/ss/symtab.c b/security/selinux/ss/symtab.c index bcf9f620426e..160326ee99e5 100644 --- a/security/selinux/ss/symtab.c +++ b/security/selinux/ss/symtab.c @@ -36,7 +36,7 @@ int symtab_init(struct symtab *s, unsigned int size) { s->table = hashtab_create(symhash, symcmp, size); if (!s->table) - return -1; + return -ENOMEM; s->nprim = 0; return 0; } |