From e85c79051cc5003568ace6a29ce6e13d16796e48 Mon Sep 17 00:00:00 2001 From: Alexander Orzechowski Date: Mon, 24 Jul 2023 02:09:28 -0400 Subject: [PATCH] wlr_output: Set current_mode during new custom mode When setting a custom mode current_mode will not be reset. That means that next time the compositor tries to reset back from the custom mode, it will compare against the stale current_mode and unset WLR_OUTPUT_STATE_MODE erroneously. --- types/output/output.c | 1 + 1 file changed, 1 insertion(+) diff --git a/types/output/output.c b/types/output/output.c index d1fda35e..81c4e39e 100644 --- a/types/output/output.c +++ b/types/output/output.c @@ -358,6 +358,7 @@ static void output_apply_state(struct wlr_output *output, } break; case WLR_OUTPUT_STATE_MODE_CUSTOM: + output->current_mode = NULL; width = state->custom_mode.width; height = state->custom_mode.height; refresh = state->custom_mode.refresh;