projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
17baa2a
)
proc_sysctl.c: use BUG_ON instead of BUG
author
Prasad Joshi
<prasadjoshi.linux@gmail.com>
Fri, 5 Oct 2012 00:15:45 +0000
(17:15 -0700)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Fri, 5 Oct 2012 18:05:18 +0000
(
03:05
+0900)
The use of if (!head) BUG(); can be replaced with the single line
BUG_ON(!head).
Signed-off-by: Prasad Joshi <prasadjoshi.linux@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/proc/proc_sysctl.c
patch
|
blob
|
history
diff --git
a/fs/proc/proc_sysctl.c
b/fs/proc/proc_sysctl.c
index eb7cc91b7258870f89b77a60de4172dd6f1502b6..dcd56f84db7ebcce37e884cae218c90d795109b0 100644
(file)
--- a/
fs/proc/proc_sysctl.c
+++ b/
fs/proc/proc_sysctl.c
@@
-266,8
+266,7
@@
void sysctl_head_put(struct ctl_table_header *head)
static struct ctl_table_header *sysctl_head_grab(struct ctl_table_header *head)
{
- if (!head)
- BUG();
+ BUG_ON(!head);
spin_lock(&sysctl_lock);
if (!use_table(head))
head = ERR_PTR(-ENOENT);