projects
/
deliverable
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
debugfs: write_file_bool() - ensure strtobool() operates on valid data
[deliverable/linux.git]
/
fs
/
debugfs
/
file.c
diff --git
a/fs/debugfs/file.c
b/fs/debugfs/file.c
index ff64bcd5b8fbac727f98ba45865bbe0d44aceaf8..63146295153ba1685c0ca5ac3cf8cb0097787e1e 100644
(file)
--- a/
fs/debugfs/file.c
+++ b/
fs/debugfs/file.c
@@
-473,6
+473,7
@@
static ssize_t write_file_bool(struct file *file, const char __user *user_buf,
if (copy_from_user(buf, user_buf, buf_size))
return -EFAULT;
+ buf[buf_size] = '\0';
if (strtobool(buf, &bv) == 0)
*val = bv;
This page took
0.025496 seconds
and
5
git commands to generate.