projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge remote-tracking branch 'asoc/fix/omap' into asoc-linus
[firefly-linux-kernel-4.4.55.git]
/
kernel
/
kprobes.c
diff --git
a/kernel/kprobes.c
b/kernel/kprobes.c
index bddf3b201a480015e2b1b15c217c43ea6796fcd0..6e33498d665c3caa35ac764a46dd27c7cec80685 100644
(file)
--- a/
kernel/kprobes.c
+++ b/
kernel/kprobes.c
@@
-2332,6
+2332,7
@@
static ssize_t write_enabled_file_bool(struct file *file,
if (copy_from_user(buf, user_buf, buf_size))
return -EFAULT;
+ buf[buf_size] = '\0';
switch (buf[0]) {
case 'y':
case 'Y':
@@
-2343,6
+2344,8
@@
static ssize_t write_enabled_file_bool(struct file *file,
case '0':
disarm_all_kprobes();
break;
+ default:
+ return -EINVAL;
}
return count;