Skip to content

Safer event queue changes

Alexandros Frantzis requested to merge afrantzis/wayland:change-event-queue into main

Improve safety of event queue changes by:

  1. Documenting the proper way to perform them to guarantee proper handling of events.
  2. Making the operation more obviously correct by introducing proper locking.

See individual commit messages for more detailed information.

This MR is driven by the WIP Wine Wayland driver, which wants to detach unreleased wl_buffers from their owning buffer queue during the buffer queue's destruction. The wl_buffers are moved from the per-buffer-queue wl_event_queues to a per-thread wl_event_queue, so that the driver can immediately destroy all buffer queue resources, while ensuring that it doesn't prematurely destroy unreleased wl_buffers (see #300).

Edited by Alexandros Frantzis

Merge request reports