diff -ru xf86-input-evdev-2.9.1/src/evdev.c xf86-input-evdev-2.9.1.new/src/evdev.c --- xf86-input-evdev-2.9.1/src/evdev.c 2014-11-26 00:33:56.000000000 +0100 +++ xf86-input-evdev-2.9.1.new/src/evdev.c 2015-01-22 15:34:48.313671266 +0100 @@ -751,6 +751,14 @@ if (ev->code == ABS_MT_SLOT) { EvdevProcessTouch(pInfo); + if (ev->value >= num_slots(pEvdev) ) { + LogMessageVerbSigSafe(X_WARNING, 0, + "%s: Slot index %d out of bounds (max %d), touch events may be incorrect.\n", + pInfo->name, + ev->value, + num_slots(pEvdev)-1); + return; + } pEvdev->cur_slot = ev->value; } else {