From 24263412dc121325ca980bd34f2b7ed097c7145b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sun, 7 Feb 2021 16:05:02 +0100 Subject: [PATCH] url-mode: urls_render(): early exit when URL list is empty --- url-mode.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/url-mode.c b/url-mode.c index 2a3ee41d..40f3372f 100644 --- a/url-mode.c +++ b/url-mode.c @@ -474,6 +474,9 @@ urls_render(struct terminal *term) struct wl_window *win = term->window; struct wayland *wayl = term->wl; + if (tll_length(win->term->urls) == 0) + return; + xassert(tll_length(win->urls) == 0); tll_foreach(win->term->urls, it) { struct wl_surface *surf = wl_compositor_create_surface(wayl->compositor);