From b3ff66dc7a2efd251977e142b224dac69eccd3f9 Mon Sep 17 00:00:00 2001 From: Tillmann Karras Date: Sat, 15 Aug 2015 12:51:34 +0200 Subject: [PATCH] evdev: don't pass null path to the kernel --- Source/Core/InputCommon/ControllerInterface/evdev/evdev.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Core/InputCommon/ControllerInterface/evdev/evdev.cpp b/Source/Core/InputCommon/ControllerInterface/evdev/evdev.cpp index d329189832..3d45244847 100644 --- a/Source/Core/InputCommon/ControllerInterface/evdev/evdev.cpp +++ b/Source/Core/InputCommon/ControllerInterface/evdev/evdev.cpp @@ -63,7 +63,7 @@ void Init(std::vector &controllerDevices) const char* devnode = udev_device_get_devnode(dev); // We only care about devices which we have read/write access to. - if (access(devnode, W_OK) == 0) + if (devnode && access(devnode, W_OK) == 0) { // Unfortunately udev gives us no way to filter out the non event device interfaces. // So we open it and see if it works with evdev ioctls or not.