diff options
-rw-r--r-- | kernel/profile.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/profile.c b/kernel/profile.c index f940b462eec9..15b012df4ff1 100644 --- a/kernel/profile.c +++ b/kernel/profile.c | |||
@@ -442,7 +442,8 @@ read_profile(struct file *file, char __user *buf, size_t count, loff_t *ppos) | |||
442 | read = 0; | 442 | read = 0; |
443 | 443 | ||
444 | while (p < sizeof(unsigned int) && count > 0) { | 444 | while (p < sizeof(unsigned int) && count > 0) { |
445 | put_user(*((char *)(&sample_step)+p),buf); | 445 | if (put_user(*((char *)(&sample_step)+p),buf)) |
446 | return -EFAULT; | ||
446 | buf++; p++; count--; read++; | 447 | buf++; p++; count--; read++; |
447 | } | 448 | } |
448 | pnt = (char *)prof_buffer + p - sizeof(atomic_t); | 449 | pnt = (char *)prof_buffer + p - sizeof(atomic_t); |