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:
5f92a7b
)
fault-inject: automatically detect the number base for fail-nth write interface
author
Akinobu Mita
<
[email protected]
>
Fri, 14 Jul 2017 21:49:49 +0000
(14:49 -0700)
committer
Linus Torvalds
<
[email protected]
>
Fri, 14 Jul 2017 22:05:13 +0000
(15:05 -0700)
Automatically detect the number base to use when writing to fail-nth
file instead of always parsing as a decimal number.
Link:
http://lkml.kernel.org/r/
[email protected]
Signed-off-by: Akinobu Mita <
[email protected]
>
Cc: Dmitry Vyukov <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
fs/proc/base.c
patch
|
blob
|
history
diff --git
a/fs/proc/base.c
b/fs/proc/base.c
index 88b773f318cd06f31ca6262bb5949728c199ade0..5d93512beea11878efe6cd2984e84ba23a728c51 100644
(file)
--- a/
fs/proc/base.c
+++ b/
fs/proc/base.c
@@
-1368,7
+1368,7
@@
static ssize_t proc_fail_nth_write(struct file *file, const char __user *buf,
put_task_struct(task);
if (task != current)
return -EPERM;
- err = kstrtoint_from_user(buf, count,
1
0, &n);
+ err = kstrtoint_from_user(buf, count, 0, &n);
if (err)
return err;
if (n < 0 || n == INT_MAX)