Commit afe305dc authored by Fabian Frederick's avatar Fabian Frederick Committed by Linus Torvalds

fs/affs/file.c: replace if/BUG by BUG_ON

Signed-off-by: default avatarFabian Frederick <fabf@skynet.be>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 08fe100d
...@@ -180,8 +180,7 @@ affs_get_extblock_slow(struct inode *inode, u32 ext) ...@@ -180,8 +180,7 @@ affs_get_extblock_slow(struct inode *inode, u32 ext)
ext_key = be32_to_cpu(AFFS_TAIL(sb, bh)->extension); ext_key = be32_to_cpu(AFFS_TAIL(sb, bh)->extension);
if (ext < AFFS_I(inode)->i_extcnt) if (ext < AFFS_I(inode)->i_extcnt)
goto read_ext; goto read_ext;
if (ext > AFFS_I(inode)->i_extcnt) BUG_ON(ext > AFFS_I(inode)->i_extcnt);
BUG();
bh = affs_alloc_extblock(inode, bh, ext); bh = affs_alloc_extblock(inode, bh, ext);
if (IS_ERR(bh)) if (IS_ERR(bh))
return bh; return bh;
...@@ -198,8 +197,7 @@ affs_get_extblock_slow(struct inode *inode, u32 ext) ...@@ -198,8 +197,7 @@ affs_get_extblock_slow(struct inode *inode, u32 ext)
struct buffer_head *prev_bh; struct buffer_head *prev_bh;
/* allocate a new extended block */ /* allocate a new extended block */
if (ext > AFFS_I(inode)->i_extcnt) BUG_ON(ext > AFFS_I(inode)->i_extcnt);
BUG();
/* get previous extended block */ /* get previous extended block */
prev_bh = affs_get_extblock(inode, ext - 1); prev_bh = affs_get_extblock(inode, ext - 1);
......
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