Skip to content

Commit

Permalink
Squashfs: frag_size should be signed, as it can hold an error result
Browse files Browse the repository at this point in the history
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
  • Loading branch information
Roel Kluin authored and Phillip Lougher committed Mar 5, 2009
1 parent edf2e28 commit f4f8056
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions fs/squashfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,8 @@ int squashfs_read_inode(struct inode *inode, long long ino)
type = le16_to_cpu(sqshb_ino->inode_type);
switch (type) {
case SQUASHFS_REG_TYPE: {
unsigned int frag_offset, frag_size, frag;
unsigned int frag_offset, frag;
int frag_size;
u64 frag_blk;
struct squashfs_reg_inode *sqsh_ino = &squashfs_ino.reg;

Expand Down Expand Up @@ -175,7 +176,8 @@ int squashfs_read_inode(struct inode *inode, long long ino)
break;
}
case SQUASHFS_LREG_TYPE: {
unsigned int frag_offset, frag_size, frag;
unsigned int frag_offset, frag;
int frag_size;
u64 frag_blk;
struct squashfs_lreg_inode *sqsh_ino = &squashfs_ino.lreg;

Expand Down

0 comments on commit f4f8056

Please sign in to comment.