git.openpandora.org
/
pandora-kernel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
microblaze: fix __get_user()
[pandora-kernel.git]
/
fs
/
xfs
/
xfs_acl.c
diff --git
a/fs/xfs/xfs_acl.c
b/fs/xfs/xfs_acl.c
index
b6c4b37
..
ac702a6
100644
(file)
--- a/
fs/xfs/xfs_acl.c
+++ b/
fs/xfs/xfs_acl.c
@@
-39,9
+39,11
@@
xfs_acl_from_disk(struct xfs_acl *aclp)
struct posix_acl_entry *acl_e;
struct posix_acl *acl;
struct xfs_acl_entry *ace;
struct posix_acl_entry *acl_e;
struct posix_acl *acl;
struct xfs_acl_entry *ace;
- int count, i;
+
unsigned
int count, i;
count = be32_to_cpu(aclp->acl_cnt);
count = be32_to_cpu(aclp->acl_cnt);
+ if (count > XFS_ACL_MAX_ENTRIES)
+ return ERR_PTR(-EFSCORRUPTED);
acl = posix_acl_alloc(count, GFP_KERNEL);
if (!acl)
acl = posix_acl_alloc(count, GFP_KERNEL);
if (!acl)