diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2009-04-06 10:22:25 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2009-04-06 10:25:03 +1000 |
commit | 98ecb5233bb3b899bd696a90d2733c6a345676dd (patch) | |
tree | 6f3e92cf3ab5b11c868e64c0b885982d6f5edc44 | |
parent | Fix wrong reference to axis and button label atom list. (diff) | |
download | xf86-input-evdev-98ecb5233bb3b899bd696a90d2733c6a345676dd.tar.gz xf86-input-evdev-98ecb5233bb3b899bd696a90d2733c6a345676dd.tar.bz2 xf86-input-evdev-98ecb5233bb3b899bd696a90d2733c6a345676dd.zip |
Trigger read error handling if len is <= 0.
Red Hat Bug 494245 <https://bugzilla.redhat.com/show_bug.cgi?id=494245>
Reported-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | src/evdev.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/evdev.c b/src/evdev.c index f65359f..43a90be 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -565,7 +565,7 @@ EvdevReadInput(InputInfoPtr pInfo) while (len == sizeof(ev)) { len = read(pInfo->fd, &ev, sizeof(ev)); - if (len == 0) + if (len <= 0) { if (errno == ENODEV) /* May happen after resume */ { |