projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
87250dd
)
locks: convert an -EINVAL return to a BUG
author
J. Bruce Fields
<bfields@citi.umich.edu>
Sat, 30 Jun 2007 16:40:32 +0000
(12:40 -0400)
committer
J. Bruce Fields
<bfields@citi.umich.edu>
Wed, 18 Jul 2007 23:09:27 +0000
(19:09 -0400)
There's no point trying to return an error in these cases, which all represent
bugs in the callers.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
fs/locks.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/locks.c
b/fs/locks.c
index 924e4a7fb1d5e449ccb534581d9abb55568195dc..3c23fd2610224b12ff37d3508e059197d181f703 100644
(file)
--- a/
fs/locks.c
+++ b/
fs/locks.c
@@
-1348,9
+1348,7
@@
static int __setlease(struct file *filp, long arg, struct file_lock **flp)
time_out_leases(inode);
- error = -EINVAL;
- if (!flp || !(*flp) || !(*flp)->fl_lmops || !(*flp)->fl_lmops->fl_break)
- goto out;
+ BUG_ON(!(*flp)->fl_lmops->fl_break);
lease = *flp;