Btrfs: use BUG_ON
Use BUG_ON(x) rather than if(x) BUG(); The semantic patch that fixes this problem is as follows: // <smpl> @@ identifier x; @@ -if (x) BUG(); +BUG_ON(x); // </smpl> Signed-off-by: Himangi Saraogi <himangi774@gmail.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Chris Mason <clm@fb.com>
This commit is contained in:
parent
7880991344
commit
14586651ed
|
@ -2677,8 +2677,8 @@ again:
|
|||
found_key.offset);
|
||||
if (ret == -ENOSPC)
|
||||
failed++;
|
||||
else if (ret)
|
||||
BUG();
|
||||
else
|
||||
BUG_ON(ret);
|
||||
}
|
||||
|
||||
if (found_key.offset == 0)
|
||||
|
|
Loading…
Reference in New Issue