git.lucas.co / cce-compositor
Wayland compositor (wlroots)
git clone https://git.lucas.co/cce-compositor.git

commit2faa72236dc6f7479c52371b0c4d845a1ee391c3
parent4fcedc5da5
authorIsaac Freund <[email protected]>
date2026-03-04 11:30
OutputManager: fix assertion on failed commit

 river/OutputManager.zig | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/river/OutputManager.zig b/river/OutputManager.zig
index 0618a31..2799e54 100644
--- a/river/OutputManager.zig
+++ b/river/OutputManager.zig
@@ -290,7 +290,8 @@ pub fn commitOutputState(om: *OutputManager) void {
                     if (mode.height != wlr_output.height) break :blk true;
                     if (mode.refresh != wlr_output.refresh) break :blk true;
                 },
-                .none => unreachable,
+                // This branch is reachable if we fail to enable an output.
+                .none => assert(output.sent.state == .disabled_hard),
             }
             // If an output newly exposed to river is already enabled, we
             // must modeset since the mode is otherwise undefined.