Wayland compositor (wlroots)
git clone https://git.lucas.co/cce-compositor.git
xdg-activation: fix race with transaction system
This code could allows the view to be focused and urgent at the
same time if the request to activate the view is received just after
the pending focus has been set but before the transaction completes.
river/Server.zig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/river/Server.zig b/river/Server.zig
index 56bb2ca..c5b0b39 100644
--- a/river/Server.zig
+++ b/river/Server.zig
@@ -289,7 +289,7 @@ fn handleRequestActivate(
const node_data = SceneNodeData.fromSurface(event.surface) orelse return;
switch (node_data.data) {
- .view => |view| if (view.current.focus == 0) {
+ .view => |view| if (view.pending.focus == 0) {
view.pending.urgent = true;
server.root.applyPending();
},