summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-03-19 20:24:06 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-03-20 14:48:57 +1000
commit7d4df0ee4414779ad5e519e7bd297c5dfec409a3 (patch)
tree3879fea32c0b31bf98f774c36d6376943b714a1c
parentf1c7b95d83948160a0d5796ef6c16fc0d1bf5c5d (diff)
dix: fix device sync state when calling SyncBoth during AllowEvents.
This did access the wrong device's sync state, potentially freezing or not thawing the actual device that was supposed to be thawed. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--dix/events.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/dix/events.c b/dix/events.c
index b45eb7ba0..5702d2f21 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -3635,12 +3635,12 @@ DeliverGrabbedEvent(InternalEvent *event, DeviceIntPtr thisDev,
if (dev == thisDev)
continue;
FreezeThaw(dev, TRUE);
- if ((grabinfo->sync.state == FREEZE_BOTH_NEXT_EVENT) &&
+ if ((dev->deviceGrab.sync.state == FREEZE_BOTH_NEXT_EVENT) &&
(CLIENT_BITS(grab->resource) ==
- CLIENT_BITS(grab->resource)))
- grabinfo->sync.state = FROZEN_NO_EVENT;
+ CLIENT_BITS(dev->deviceGrab.sync.other->resource)))
+ dev->deviceGrab.sync.state = FROZEN_NO_EVENT;
else
- grabinfo->sync.other = grab;
+ dev->deviceGrab.sync.other = grab;
}
/* fall through */
case FREEZE_NEXT_EVENT: