The array needs to be filled with zeros, otherwise we may end up sending
it with random values if non-zero values aren't in one row (which is the
case for A4Tech X-750F which sends REL_MISC events without a reason).

X.Org Bug 24737 <http://bugs.freedesktop.org/show_bug.cgi?id=24737>

Signed-off-by: Bartosz Brachaczek <[email protected]>
Tested-by: Bartek Iwaniec <[email protected]>
---
 src/evdev.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/evdev.c b/src/evdev.c
index 18f3fb7..31fe1d6 100644
--- a/src/evdev.c
+++ b/src/evdev.c
@@ -662,7 +662,7 @@ static void
 EvdevProcessSyncEvent(InputInfoPtr pInfo, struct input_event *ev)
 {
     int num_v = 0, first_v = 0;
-    int v[MAX_VALUATORS];
+    int v[MAX_VALUATORS] = {};
     EvdevPtr pEvdev = pInfo->private;

     EvdevProcessValuators(pInfo, v, &num_v, &first_v);
-- 
1.7.2
_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to