AW: BadAccess to a GrabButton

Walter Harms wharms at bfs.de
Mon May 4 07:57:14 UTC 2020


Hi  Sam Varshavchik,
could you please elaborate a bit what you are doing exactly ?
Someone should be able to replicate that you are doing.

You have a (simple) programm you can share ?
Even pseudo code would be ok.

re,
 wh
________________________________________
Von: xorg <xorg-bounces at lists.x.org> im Auftrag von Sam Varshavchik <sam.varshavchik at gmail.com>
Gesendet: Sonntag, 3. Mai 2020 01:31:20
An: xorg at lists.x.org
Betreff: BadAccess to a GrabButton

I'm running automated tests that map/unmap things quickly, amongst other
things. I am getting a BadAccess in response to one of the GrabButton
requestrs, and I can't figure out why (x11trace):

000:>:0705:Error 10=Access: major=28, minor=0, bad=79691853

X documentation says that BadAccess results from either a conflicting grab
from another client or if I already have another passive grab.

Grepping x11trace log, these are the only GrabButton and UngrabButton events
I see:

000:<:053b: 24: Request(28): GrabButton owner-events=false(0x00)
grab-window=0x04c00003
event-mask=ButtonPress,ButtonRelease,EnterWindow,LeaveWindow,PointerMotion
pointer-mode=Synchronous(0x00) keyboard-mode=Synchronous(0x00)
confine-to=None(0x00000000) cursor=None(0x00000000) button=any
button(0x00) modifiers=AnyModifier
000:<:06ae: 24: Request(28): GrabButton owner-events=false(0x00)
grab-window=0x04c0004d
event-mask=ButtonPress,ButtonRelease,EnterWindow,LeaveWindow,PointerMotion
pointer-mode=Synchronous(0x00) keyboard-mode=Synchronous(0x00)
confine-to=None(0x00000000) cursor=None(0x00000000) button=any
button(0x00) modifiers=AnyModifier
000:<:06d1: 12: Request(29): UngrabButton button=any button(0x00)
grab-window=0x04c0004d modifiers=AnyModifier
000:<:0705: 24: Request(28): GrabButton owner-events=false(0x00)
grab-window=0x04c0004d
event-mask=ButtonPress,ButtonRelease,EnterWindow,LeaveWindow,PointerMotion
pointer-mode=Synchronous(0x00) keyboard-mode=Synchronous(0x00)
confine-to=None(0x00000000) cursor=None(0x00000000) button=any
button(0x00) modifiers=AnyModifier
000:<:071c: 12: Request(29): UngrabButton button=any button(0x00)
grab-window=0x04c0004d modifiers=AnyModifier
000:<:071f: 12: Request(29): UngrabButton button=any button(0x00)
grab-window=0x04c00003 modifiers=AnyModifier

Request 0705 is the one that returned an error. I do not see any conflicts
here.

I do not get a BadAccess if I add a flush and a sleep, after the grabs, so
there must be a race condition somewhere?
_______________________________________________
xorg at lists.x.org: X.Org support
Archives: http://lists.freedesktop.org/archives/xorg
Info: https://lists.x.org/mailman/listinfo/xorg
Your subscription address: %(user_address)s


More information about the xorg mailing list