aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/dix/dispatch.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/dix/dispatch.c')
-rw-r--r--xorg-server/dix/dispatch.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/xorg-server/dix/dispatch.c b/xorg-server/dix/dispatch.c
index 104dcc9b3..d97180548 100644
--- a/xorg-server/dix/dispatch.c
+++ b/xorg-server/dix/dispatch.c
@@ -214,7 +214,7 @@ UpdateCurrentTimeIf(void)
systime.milliseconds = GetTimeInMillis();
if (systime.milliseconds < currentTime.milliseconds)
systime.months++;
- if (*checkForInput[0] == *checkForInput[1])
+ if (CompareTimeStamps(systime, currentTime) == LATER)
currentTime = systime;
}
@@ -393,6 +393,9 @@ Dispatch(void)
}
/* now, finally, deal with client requests */
+ /* Update currentTime so request time checks, such as for input
+ * device grabs, are calculated correctly */
+ UpdateCurrentTimeIf();
result = ReadRequestFromClient(client);
if (result <= 0) {
if (result < 0)
@@ -413,8 +416,8 @@ Dispatch(void)
if (XSERVER_REQUEST_START_ENABLED())
XSERVER_REQUEST_START(LookupMajorName(client->majorOp),
client->majorOp,
- ((xReq *) client->requestBuffer)->
- length, client->index,
+ ((xReq *) client->requestBuffer)->length,
+ client->index,
client->requestBuffer);
#endif
if (result > (maxBigRequestSize << 2))