mirror of
https://gitlab.freedesktop.org/libevdev/libevdev.git
synced 2025-12-22 20:40:06 +01:00
uinput: check errno against the positive value
We use the negative errno internally, but the proper errno is always positive. Fixes device creation failures on kernels that don't support UI_SET_PROPBIT. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
This commit is contained in:
parent
a5f150ef57
commit
09529a6a65
1 changed files with 1 additions and 1 deletions
|
|
@ -147,7 +147,7 @@ set_props(const struct libevdev *dev, int fd, struct uinput_user_dev *uidev)
|
|||
* ioctl is called on an already created device. The
|
||||
* last two can't happen here.
|
||||
*/
|
||||
if (errno == -EINVAL)
|
||||
if (errno == EINVAL)
|
||||
rc = 0;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue