Skip to content

Commit

Permalink
UBIFS: remove BUG statement
Browse files Browse the repository at this point in the history
Remove a 'BUG()' statement when we are unable to find a bud and add a
similar 'ubifs_assert()' statement instead.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
  • Loading branch information
Artem Bityutskiy authored and Artem Bityutskiy committed May 16, 2011
1 parent e76a452 commit c49139d
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions fs/ubifs/replay.c
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,6 @@ static int replay_bud(struct ubifs_info *c, struct bud_entry *b)
int jhead = b->bud->jhead;
struct ubifs_scan_leb *sleb;
struct ubifs_scan_node *snod;
struct ubifs_bud *bud;

dbg_mnt("replay bud LEB %d, head %d, offs %d", lnum, jhead, offs);

Expand Down Expand Up @@ -608,10 +607,7 @@ static int replay_bud(struct ubifs_info *c, struct bud_entry *b)
goto out;
}

bud = ubifs_search_bud(c, lnum);
if (!bud)
BUG();

ubifs_assert(ubifs_search_bud(c, lnum));
ubifs_assert(sleb->endpt - offs >= used);
ubifs_assert(sleb->endpt % c->min_io_size == 0);

Expand Down

0 comments on commit c49139d

Please sign in to comment.