Missing events sometimes

Olivier Fourdan fourdan at gmail.com
Fri Oct 28 06:17:23 PDT 2011


Hi Peter,

On Fri, Oct 28, 2011 at 12:44 AM, Peter Hutterer
<peter.hutterer at who-t.net> wrote:
[...]
>
> I'm not sure on the actual code but there's a race condition for both - if
> the release event happens before the server receives/processes the
> GrabKey/Pointer request you may drop the event on the floor. This shouldn't
> happen since you should get it delivered based on the passive grab either
> way but there's a chance the client drops it.
> Try swapping the passive grab to sync and see if that avoids it.

Yeap it works, this plus an XAllowEvents(dpy, SyncKeyboard, ev->time)
that nails it!

[...]
>
> put a delay in before XGrabPointer in the client and click fast (so that the
> release happens before the request). this way you can easily verify if it is
> that race condition or something else.

Many thanks!

Cheers,
Olivier



More information about the xorg mailing list