From 74933c40eec496cdd055822e661240e21fbd7433 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sat, 11 Jul 2020 07:37:01 +0200 Subject: [PATCH] bar/wayland: log error message when failing to load cursor (image) --- bar/wayland.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bar/wayland.c b/bar/wayland.c index 31c220a..13cff16 100644 --- a/bar/wayland.c +++ b/bar/wayland.c @@ -1200,6 +1200,11 @@ set_cursor(struct bar *_bar, const char *cursor) seat->pointer.cursor = wl_cursor_theme_get_cursor( seat->pointer.theme, cursor); + if (seat->pointer.cursor == NULL) { + LOG_ERR("%s: failed to load cursor '%s'", seat->name, cursor); + return; + } + update_cursor_surface(backend, seat); }