client: reject prepare_read if the display has an error

Signed-off-by: Julian Orth <ju.orth@gmail.com>
This commit is contained in:
Julian Orth 2025-04-18 16:32:04 +02:00
parent b43b06d31c
commit a22280d78d

View file

@ -1904,7 +1904,7 @@ wl_display_prepare_read_queue(struct wl_display *display,
has_events = !wl_list_empty(&queue->event_list) ||
!wl_list_empty(&display->display_queue.event_list);
if (has_events) {
if (has_events || display->last_error) {
errno = EAGAIN;
ret = -1;
} else {