aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-02-16 15:11:20 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-02-16 15:11:20 +1000
commit5a99ef7ed21ff879b6c55027590733bc7a9c6742 (patch)
tree0c5020e17b1aab7ca36a9aae277326244e736995
parentman: list the options and properties in alphabetical order. (diff)
downloadxf86-input-evdev-5a99ef7ed21ff879b6c55027590733bc7a9c6742.tar.gz
xf86-input-evdev-5a99ef7ed21ff879b6c55027590733bc7a9c6742.tar.bz2
xf86-input-evdev-5a99ef7ed21ff879b6c55027590733bc7a9c6742.zip
remove duplicate (code > 255) check.
-rw-r--r--src/evdev.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/src/evdev.c b/src/evdev.c
index a62ebe7..8d7b196 100644
--- a/src/evdev.c
+++ b/src/evdev.c
@@ -259,16 +259,18 @@ PostKbdEvent(InputInfoPtr pInfo, struct input_event *ev, int value)
if (value == 2)
return;
- if (code > 255 && ev->code <= KEY_MAX) {
- if (!warned[ev->code])
- xf86Msg(X_WARNING, "%s: unable to handle keycode %d\n",
- pInfo->name, ev->code);
- warned[ev->code] = 1;
- }
-
- /* The X server can't handle keycodes > 255 anyway, just drop them. */
if (code > 255)
+ {
+ if (ev->code <= KEY_MAX && !warned[ev->code])
+ {
+ xf86Msg(X_WARNING, "%s: unable to handle keycode %d\n",
+ pInfo->name, ev->code);
+ warned[ev->code] = 1;
+ }
+
+ /* The X server can't handle keycodes > 255. */
return;
+ }
xf86PostKeyboardEvent(pInfo->dev, code, value);
}