mirror of
https://github.com/openai/codex.git
synced 2026-11-26 23:40:43 +00:00
## Why The TUI disabled PRIMARY whenever `WAYLAND_DISPLAY` was set, so it couldn't publish selected text to PRIMARY or paste from it with a middle click in Wayland sessions. ## What changed Probe Wayland PRIMARY support in the background and use the result for selection copying and middle-click paste. If the compositor lacks the Wayland data-control protocol, allow XWayland fallback only when the Wayland and X11 sockets have matching listener credentials. ## Testing Add a unit test covering native Wayland support, the same-session XWayland fallback, remote X11 displays, and unsuccessful probes. GitOrigin-RevId: 9b5c1536762383c0fe770dd86d58a49a1f3633a8