dwl

My patch set and modifications to dwl
git clone git://git.ethandl.dev/dwl
Log | Files | Refs | README | LICENSE

commit bcc8ce7a40d30023eb97934419c2102c91846563
parent ba7dcb2dea2d5dc46b73b6b9194daab94a325a05
Author: Leonardo Hernández Hernández <leohdz172@protonmail.com>
Date:   Sun, 18 Sep 2022 15:16:10 -0500

fix segfault when unlocking swaylock on two monitor setup

wlr_*_surface_from_wlr_surface() can return NULL if the surface
is being destroyed

Fixes: https://github.com/djpohly/dwl/issues/305

Diffstat:
Mdwl.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dwl.c b/dwl.c @@ -1175,7 +1175,7 @@ focusclient(Client *c, int lift) struct wlr_layer_surface_v1 *wlr_layer_surface = wlr_layer_surface_v1_from_wlr_surface(old); - if (wlr_layer_surface->mapped && ( + if (wlr_layer_surface && wlr_layer_surface->mapped && ( wlr_layer_surface->current.layer == ZWLR_LAYER_SHELL_V1_LAYER_TOP || wlr_layer_surface->current.layer == ZWLR_LAYER_SHELL_V1_LAYER_OVERLAY ))