Commit 3cdc409c authored by Adrian Bunk's avatar Adrian Bunk Committed by Linus Torvalds

[PATCH] reiserfs/xattr_acl.c:reiserfs_get_acl(): make size an int

The Coverity checker wasn't happy seeing a size_t compared with -ENODATA
and -ENOSYS.

Since the only place where size is set is through the result of
reiserfs_xattr_get() which is an int, we could simply make size an int.
Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
Cc: Jeff Mahoney <jeffm@suse.com>
Cc: Chris Mason <mason@suse.com>
Cc: Hans Reiser <reiser@namesys.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 340e48e6
...@@ -182,7 +182,7 @@ struct posix_acl *reiserfs_get_acl(struct inode *inode, int type) ...@@ -182,7 +182,7 @@ struct posix_acl *reiserfs_get_acl(struct inode *inode, int type)
{ {
char *name, *value; char *name, *value;
struct posix_acl *acl, **p_acl; struct posix_acl *acl, **p_acl;
size_t size; int size;
int retval; int retval;
struct reiserfs_inode_info *reiserfs_i = REISERFS_I(inode); struct reiserfs_inode_info *reiserfs_i = REISERFS_I(inode);
...@@ -206,7 +206,7 @@ struct posix_acl *reiserfs_get_acl(struct inode *inode, int type) ...@@ -206,7 +206,7 @@ struct posix_acl *reiserfs_get_acl(struct inode *inode, int type)
return posix_acl_dup(*p_acl); return posix_acl_dup(*p_acl);
size = reiserfs_xattr_get(inode, name, NULL, 0); size = reiserfs_xattr_get(inode, name, NULL, 0);
if ((int)size < 0) { if (size < 0) {
if (size == -ENODATA || size == -ENOSYS) { if (size == -ENODATA || size == -ENOSYS) {
*p_acl = ERR_PTR(-ENODATA); *p_acl = ERR_PTR(-ENODATA);
return NULL; return NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment