From d40220e51196e517c97602ec7a236236c4701481 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Mon, 15 Nov 2021 18:06:10 +0100 Subject: [PATCH] bar/wayland: handle failure to set initial size in setup() --- bar/wayland.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bar/wayland.c b/bar/wayland.c index 90d1103..a5a6731 100644 --- a/bar/wayland.c +++ b/bar/wayland.c @@ -1025,7 +1025,8 @@ setup(struct bar *_bar) ZWLR_LAYER_SURFACE_V1_ANCHOR_RIGHT | top_or_bottom); - update_size(backend); + if (!update_size(backend)) + return false; assert(backend->monitor == NULL || backend->width / backend->monitor->scale <= backend->monitor->width_px);