From 763edd37305e789bcc31746e5ea41f4df9d0b2a4 Mon Sep 17 00:00:00 2001 From: "Zephaniah E. Hull" Date: Mon, 20 Feb 2006 09:18:56 +0000 Subject: Bugzilla #5950 Possible (maybe) fix for bug #5950. Though, I'm not convinced and still don't see how this bug could be happening, especially if this doesn't do it. --- ChangeLog | 8 ++++++++ src/evdev_btn.c | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index b8b04e6..86ba633 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2006-02-20 Zephaniah E. Hull,,, + + * src/evdev_btn.c: (EvdevBtnInit): + Bugzilla #5950 + Possible (maybe) fix for bug #5950. + Though, I'm not convinced and still don't see how this bug could + be happening, especially if this doesn't do it. + 2006-02-19 Zephaniah E. Hull * src/evdev_key.c: (EvdevKbdBell): diff --git a/src/evdev_btn.c b/src/evdev_btn.c index cc279ff..9a2c2cf 100644 --- a/src/evdev_btn.c +++ b/src/evdev_btn.c @@ -87,9 +87,9 @@ EvdevBtnInit (DeviceIntPtr device) if (!pEvdev->state.buttons) return Success; - map = Xcalloc (sizeof (CARD8) * pEvdev->state.buttons); + map = Xcalloc (sizeof (CARD8) * (pEvdev->state.buttons + 1)); - for (i = 0; i < pEvdev->state.buttons; i++) + for (i = 0; i <= pEvdev->state.buttons; i++) map[i] = i; xf86Msg(X_ERROR, "%s (%d): Registering %d buttons.\n", __FILE__, __LINE__, -- cgit v1.2.3