Compare commits

...

6 Commits

Author SHA1 Message Date
Peter Hutterer
891bfc56be evdev 2.0.8
Expect this to be the last 2.0.x release.
2008-11-18 17:16:33 +10:00
Julien Cristau
6626ad5cb9 Fix TestBit() on 64bit
Reported by Albert Damen <albrt@gmx.net>
X.Org Bug#18150 <http://bugs.freedesktop.org/show_bug.cgi?id=18150>
(cherry picked from commit f57e8face9)
2008-10-22 08:49:27 +10:30
Peter Hutterer
ae247ff09c evdev 2.0.7 2008-10-17 11:42:21 +10:30
Peter Hutterer
46f2b83e01 Don't post keycodes > 255.
If we only have keys > 255 we don't set up a key class rec, so don't post
them. It makes the server unhappy.

Signed-off-by: Julien Cristau <jcristau@debian.org>
(cherry picked from commit 7243116f55)
2008-10-17 11:19:06 +10:30
Peter Hutterer
d73a1732c6 Fix "Device reopened after N attempts" message.
(cherry picked from commit 0089d931ac)
2008-10-17 11:18:22 +10:30
Julien Cristau
8c332a8367 Set pInfo->fd to -1 on DEVICE_CLOSE
This allows the reopen logic to kick in later.
DEVICE_CLOSE gets called on regen, so without this we'd keep a stale
file descriptor in pInfo->fd in subsequent sessions.

Debian bug#496101 (http://bugs.debian.org/496101)
(cherry picked from commit b0b6399023bcdbb3337027f85c8da42d8b18c983)
2008-10-13 11:01:29 +10:30
2 changed files with 11 additions and 6 deletions

View File

@@ -22,7 +22,7 @@
AC_PREREQ(2.57)
AC_INIT([xf86-input-evdev],
2.0.6,
2.0.8,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
xf86-input-evdev)

View File

@@ -155,6 +155,10 @@ PostKbdEvent(InputInfoPtr pInfo, struct input_event *ev, int value)
warned[ev->code] = 1;
}
/* The X server can't handle keycodes > 255 anyway, just drop them. */
if (code > 255)
return;
xf86PostKeyboardEvent(pInfo->dev, code, value);
}
@@ -176,12 +180,10 @@ EvdevReopenTimer(OsTimerPtr timer, CARD32 time, pointer arg)
if (pInfo->fd != -1)
{
pEvdev->reopen_left = 0;
if (EvdevCacheCompare(pInfo, TRUE) == Success)
{
xf86Msg(X_INFO, "%s: Device reopened after %d attempts.\n", pInfo->name,
pEvdev->reopen_attempts - pEvdev->reopen_left);
pEvdev->reopen_attempts - pEvdev->reopen_left + 1);
EvdevOn(pInfo->dev);
} else
{
@@ -191,6 +193,7 @@ EvdevReopenTimer(OsTimerPtr timer, CARD32 time, pointer arg)
close(pInfo->fd);
pInfo->fd = -1;
}
pEvdev->reopen_left = 0;
return 0;
}
@@ -378,7 +381,7 @@ EvdevReadInput(InputInfoPtr pInfo)
}
}
#define TestBit(bit, array) (array[(bit) / LONG_BITS]) & (1 << ((bit) % LONG_BITS))
#define TestBit(bit, array) (array[(bit) / LONG_BITS]) & (1L << ((bit) % LONG_BITS))
static void
EvdevPtrCtrlProc(DeviceIntPtr device, PtrCtrl *ctrl)
@@ -986,8 +989,10 @@ EvdevProc(DeviceIntPtr device, int what)
case DEVICE_CLOSE:
xf86Msg(X_INFO, "%s: Close\n", pInfo->name);
if (pInfo->fd != -1)
if (pInfo->fd != -1) {
close(pInfo->fd);
pInfo->fd = -1;
}
break;
}