From ec796afb6e7fdcdd9aa1e616e703cedc195d3e33 Mon Sep 17 00:00:00 2001 From: Alexander Orzechowski Date: Wed, 3 May 2023 23:50:05 -0400 Subject: [PATCH] wlr_compositor: Decide opacity from new has_buffer flag. `wlr_surface_get_texture` will always return NULL if the compositor was not given a renderer. --- types/wlr_compositor.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/types/wlr_compositor.c b/types/wlr_compositor.c index 7bf4d7c3..0236c40f 100644 --- a/types/wlr_compositor.c +++ b/types/wlr_compositor.c @@ -390,8 +390,7 @@ static void surface_apply_damage(struct wlr_surface *surface) { } static void surface_update_opaque_region(struct wlr_surface *surface) { - struct wlr_texture *texture = wlr_surface_get_texture(surface); - if (texture == NULL) { + if (!surface->has_buffer) { pixman_region32_clear(&surface->opaque_region); return; }