summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-03-24 11:24:02 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-05-05 11:07:00 +1000
commit372ab4c9b66e3d267e35275d3d2597cdb594ed73 (patch)
tree135805841a50abd649818080f092fe840e017646
parent881f85578ab4a7c02375bcfc10026ad1a0800cdb (diff)
Shut up valgrind warnings about uninitialized variables.
Reported-by: Zdenek Kabelac <zkabelac@redhat.com> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> (cherry picked from commit 18442d927f6cf03e7a366f6c3c0292b065ba1c64)
-rw-r--r--src/eventcomm.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/eventcomm.c b/src/eventcomm.c
index 3b03695..5b38c28 100644
--- a/src/eventcomm.c
+++ b/src/eventcomm.c
@@ -78,9 +78,9 @@ static Bool
event_query_is_touchpad(int fd)
{
int ret;
- unsigned long evbits[NBITS(EV_MAX)];
- unsigned long absbits[NBITS(ABS_MAX)];
- unsigned long keybits[NBITS(KEY_MAX)];
+ unsigned long evbits[NBITS(EV_MAX)] = {0};
+ unsigned long absbits[NBITS(ABS_MAX)] = {0};
+ unsigned long keybits[NBITS(KEY_MAX)] = {0};
/* Check for ABS_X, ABS_Y, ABS_PRESSURE and BTN_TOOL_FINGER */
@@ -139,8 +139,8 @@ event_query_axis_ranges(LocalDevicePtr local)
{
SynapticsPrivate *priv = (SynapticsPrivate *)local->private;
struct input_absinfo abs;
- unsigned long absbits[NBITS(ABS_MAX)];
- unsigned long keybits[NBITS(KEY_MAX)];
+ unsigned long absbits[NBITS(ABS_MAX)] = {0};
+ unsigned long keybits[NBITS(KEY_MAX)] = {0};
char buf[256];
int rc;