diff options
| author | John Stultz <john.stultz@linaro.org> | 2011-05-20 15:29:44 -0700 |
|---|---|---|
| committer | John Stultz <john.stultz@linaro.org> | 2011-05-20 15:29:44 -0700 |
| commit | 4c24965e21c2226d2bd3dcd1f81b1b15d2fdf8a9 (patch) | |
| tree | ee67e690a0a85413a0274547e7960a744f815c8c /security | |
| parent | 5ea756bf0d0fbe2837b81365ea5af978e19bec77 (diff) | |
| parent | c5aa2077c8bae6dcb5fc185b029fc084ec4a5202 (diff) | |
Merge branch 'upstream/linaro.38' into linaro-android.38-test
Diffstat (limited to 'security')
| -rw-r--r-- | security/selinux/ss/policydb.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/security/selinux/ss/policydb.c b/security/selinux/ss/policydb.c index 57363562f0f..f96f09cdd03 100644 --- a/security/selinux/ss/policydb.c +++ b/security/selinux/ss/policydb.c @@ -497,7 +497,7 @@ static int policydb_index(struct policydb *p) goto out; rc = flex_array_prealloc(p->type_val_to_struct_array, 0, - p->p_types.nprim - 1, GFP_KERNEL | __GFP_ZERO); + p->p_types.nprim, GFP_KERNEL | __GFP_ZERO); if (rc) goto out; @@ -514,7 +514,7 @@ static int policydb_index(struct policydb *p) goto out; rc = flex_array_prealloc(p->sym_val_to_name[i], - 0, p->symtab[i].nprim - 1, + 0, p->symtab[i].nprim, GFP_KERNEL | __GFP_ZERO); if (rc) goto out; @@ -2286,7 +2286,7 @@ int policydb_read(struct policydb *p, void *fp) goto bad; /* preallocate so we don't have to worry about the put ever failing */ - rc = flex_array_prealloc(p->type_attr_map_array, 0, p->p_types.nprim - 1, + rc = flex_array_prealloc(p->type_attr_map_array, 0, p->p_types.nprim, GFP_KERNEL | __GFP_ZERO); if (rc) goto bad; |
