From 2f8736b986786f526efbd2bb6863ed39bba4d3e0 Mon Sep 17 00:00:00 2001 From: Ben Jargowsky Date: Sun, 15 May 2022 13:18:40 +0200 Subject: Check if XWayland client size_hints are NULL --- client.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/client.h b/client.h index a7b546a..e0964da 100644 --- a/client.h +++ b/client.h @@ -215,8 +215,13 @@ client_min_size(Client *c, int *width, int *height) if (client_is_x11(c)) { struct wlr_xwayland_surface_size_hints *size_hints; size_hints = c->surface.xwayland->size_hints; - *width = size_hints->min_width; - *height = size_hints->min_height; + if (size_hints) { + *width = size_hints->min_width; + *height = size_hints->min_height; + } else { + *width = 0; + *height = 0; + } return; } #endif -- cgit v1.2.3