Commit 163d2770 authored by Dan Carpenter's avatar Dan Carpenter Committed by Dmitry Torokhov

Input: uinput - reversed test in uinput_setup_device()

The test here is reversed. It should be if (IS_ERR()) instead of
if (!IS_ERR()).
Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
parent 919ed895
...@@ -362,7 +362,7 @@ static int uinput_setup_device(struct uinput_device *udev, const char __user *bu ...@@ -362,7 +362,7 @@ static int uinput_setup_device(struct uinput_device *udev, const char __user *bu
dev = udev->dev; dev = udev->dev;
user_dev = memdup_user(buffer, sizeof(struct uinput_user_dev)); user_dev = memdup_user(buffer, sizeof(struct uinput_user_dev));
if (!IS_ERR(user_dev)) if (IS_ERR(user_dev))
return PTR_ERR(user_dev); return PTR_ERR(user_dev);
udev->ff_effects_max = user_dev->ff_effects_max; udev->ff_effects_max = user_dev->ff_effects_max;
......
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