aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
m---------deps/zig-wlroots0
-rw-r--r--river/Root.zig11
2 files changed, 11 insertions, 0 deletions
diff --git a/deps/zig-wlroots b/deps/zig-wlroots
-Subproject 96dfdc14e99468f4aa6560c8397cd4d0eb0c282
+Subproject 9901da0c3b1a393248a13cc81bc282cfac8d687
diff --git a/river/Root.zig b/river/Root.zig
index b0c1d8d..a3bd35a 100644
--- a/river/Root.zig
+++ b/river/Root.zig
@@ -770,6 +770,17 @@ fn processOutputConfig(
var proposed_state = wlr.Output.State.init();
head.state.apply(&proposed_state);
+ // Work around a division by zero in the wlroots drm backend.
+ // See https://gitlab.freedesktop.org/wlroots/wlroots/-/issues/3791
+ // TODO(wlroots) remove this workaround after 0.17.2 is out.
+ if (output.wlr_output.isDrm() and
+ proposed_state.committed.mode and
+ proposed_state.mode_type == .custom and
+ proposed_state.custom_mode.refresh == 0)
+ {
+ proposed_state.custom_mode.refresh = 60000;
+ }
+
switch (action) {
.test_only => {
if (!wlr_output.testState(&proposed_state)) success = false;