summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perl-install/NEWS1
-rw-r--r--perl-install/detect_devices.pm2
2 files changed, 2 insertions, 1 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS
index d9ce9e379..61efd0828 100644
--- a/perl-install/NEWS
+++ b/perl-install/NEWS
@@ -1,5 +1,6 @@
- detecting input devices:
o display the real accessed /dev/input/eventX file (mga#8232)
+ o do not crash if /dev/input/eventX doesn't exist (mga#10296)
- draksec:
o use expanders for clarity
diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm
index 184a1db31..76e6e2a24 100644
--- a/perl-install/detect_devices.pm
+++ b/perl-install/detect_devices.pm
@@ -565,7 +565,7 @@ sub getInputDevices() {
#- KEY=30000 0 0 0 0 0 0 0 0 #=> BTN_LEFT BTN_RIGHT
#- KEY=70000 0 0 0 0 0 0 0 0 #=> BTN_LEFT BTN_RIGHT BTN_MIDDLE
#- KEY=1f0000 0 0 0 0 0 0 0 0 #=> BTN_LEFT BTN_RIGHT BTN_MIDDLE BTN_SIDE BTN_EXTRA
- if (! -f "/dev/input/$event") {
+ if (!$> && ! -f "/dev/input/$event") {
devices::make("/dev/input/$event");
}
my @KEYS = c::EVIocGBitKey("/dev/input/$event");