We guess ten simultaneous touches if the device does not tell us. The Linux drivers for the Apple multitouch trackpads do not tell the number of simultaneous touches, but they can do more than ten. When this occurs, the array index into the touch records will be invalid. We must not process the touch or else we will segfault.
Signed-off-by: Chase Douglas <[email protected]> --- src/eventcomm.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/src/eventcomm.c b/src/eventcomm.c index 3ceb98c..9d1233c 100644 --- a/src/eventcomm.c +++ b/src/eventcomm.c @@ -564,6 +564,9 @@ EventProcessTouchEvent(InputInfoPtr pInfo, struct SynapticsHwState *hw, { int slot_index = last_mt_vals_slot(priv); + if (slot_index < 0) + return; + if (hw->slot_state[slot_index] == SLOTSTATE_EMPTY || hw->slot_state[slot_index] == SLOTSTATE_OPEN_EMPTY) hw->slot_state[slot_index] = SLOTSTATE_UPDATE; -- 1.7.9.1 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
