Merge branch 'zero-resolution' into 'master'

output-swapchain-manager: Reject zero resolution

See merge request wlroots/wlroots!5246
This commit is contained in:
Kenny Levinsen 2026-01-22 11:55:55 +00:00
commit a7f7369a44

View file

@ -108,6 +108,10 @@ static bool manager_output_prepare(struct wlr_output_swapchain_manager_output *m
int width, height;
output_pending_resolution(output, state, &width, &height);
if (width == 0 || height == 0) {
wlr_log(WLR_DEBUG, "Cannot allocate swapchain for zero resolution (%dx%d)", width, height);
return false;
}
uint32_t fmt = output->render_format;
if (state->committed & WLR_OUTPUT_STATE_RENDER_FORMAT) {