mirror of
https://gitlab.freedesktop.org/xorg/lib/libx11.git
synced 2026-05-07 15:38:05 +02:00
Ensure that _XReadEvents always leaves an event in the queue on return
XNextEvent assumes that the event queue will be non-empty on return from _XReadEvents, but with multiple event readers running, the previous change could leave the queue empty on return from process_responses. Re-invoke process_responses until the queue is non-empty. Signed-off-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
parent
bedfe68259
commit
2dbaaab9c4
1 changed files with 3 additions and 1 deletions
|
|
@ -267,7 +267,9 @@ void _XReadEvents(Display *dpy)
|
|||
if(dpy->xcb->event_owner != XlibOwnsEventQueue)
|
||||
return;
|
||||
check_internal_connections(dpy);
|
||||
process_responses(dpy, 1, 0, 0);
|
||||
do {
|
||||
process_responses(dpy, 1, 0, 0);
|
||||
} while (dpy->qlen == 0);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue