Skip to content

Fix potential spin loop when a read on the Wayland socket initially fails - #3

Open
lilyyy411 wants to merge 1 commit into
Ciantic:mainfrom
lilyyy411:main
Open

Fix potential spin loop when a read on the Wayland socket initially fails#3
lilyyy411 wants to merge 1 commit into
Ciantic:mainfrom
lilyyy411:main

Conversation

@lilyyy411

Copy link
Copy Markdown

The current handling of reading the Wayland socket lends itself to accidentally causing a spin loop when there are many events or there are multiple threads reading/writing events to the Wayland socket. read_without_dispatch without a corresponding call to dispatch_inner_queue is especially prone to accidentally causing a spin loop.

The thing is that we don't need a read_without_dispatch here and, in fact, we want the behavior of read because we want the events to leave the backend's inner queue and enter the EventQueue so they can be dispatched through the application.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant