Skip to content

Commit

Permalink
squashfs: fix warn_on when root inode is corrupted
Browse files Browse the repository at this point in the history
Fix warn_on triggered by mounting a fsfuzzer corrupted file system, where
the root inode has been corrupted.

Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
Reported-by: Steve Grubb <sgrubb@redhat.com>
  • Loading branch information
Phillip Lougher committed Apr 25, 2010
1 parent 792590c commit 1cb08e9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/squashfs/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,8 @@ static int squashfs_fill_super(struct super_block *sb, void *data, int silent)

err = squashfs_read_inode(root, root_inode);
if (err) {
iget_failed(root);
make_bad_inode(root);
iput(root);
goto failed_mount;
}
insert_inode_hash(root);
Expand Down

0 comments on commit 1cb08e9

Please sign in to comment.