Commit 8abf6a4707cfb95ca552b882959c6f8ff9924270
Committed by
Adrian Bunk
1 parent
b638548384
Exists in
master
and in
39 other branches
BUG_ON() Conversion in fs/dquot.c
this changes if() BUG(); constructs to BUG_ON() which is cleaner and can better optimized away Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
Showing 1 changed file with 2 additions and 4 deletions Side-by-side Diff
fs/dquot.c
... | ... | @@ -590,8 +590,7 @@ |
590 | 590 | atomic_dec(&dquot->dq_count); |
591 | 591 | #ifdef __DQUOT_PARANOIA |
592 | 592 | /* sanity check */ |
593 | - if (!list_empty(&dquot->dq_free)) | |
594 | - BUG(); | |
593 | + BUG_ON(!list_empty(&dquot->dq_free)); | |
595 | 594 | #endif |
596 | 595 | put_dquot_last(dquot); |
597 | 596 | spin_unlock(&dq_list_lock); |
... | ... | @@ -666,8 +665,7 @@ |
666 | 665 | return NODQUOT; |
667 | 666 | } |
668 | 667 | #ifdef __DQUOT_PARANOIA |
669 | - if (!dquot->dq_sb) /* Has somebody invalidated entry under us? */ | |
670 | - BUG(); | |
668 | + BUG_ON(!dquot->dq_sb); /* Has somebody invalidated entry under us? */ | |
671 | 669 | #endif |
672 | 670 | |
673 | 671 | return dquot; |