Commit c9e33c8f authored by Randy Dunlap's avatar Randy Dunlap Committed by Linus Torvalds

[PATCH] janitor: input/evdev fix copy_user fault

From: Daniele Bellucci <bellucda@tiscali.it>
parent 259bf51c
......@@ -218,7 +218,7 @@ static int evdev_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
return put_user(EV_VERSION, (int *) arg);
case EVIOCGID:
return copy_to_user((void *) arg, &dev->id, sizeof(struct input_id));
return copy_to_user((void *) arg, &dev->id, sizeof(struct input_id)) ? -EFAULT : 0;
case EVIOCGREP:
if (put_user(dev->rep[0], ((int *) arg) + 0)) return -EFAULT;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment