From 8b047852f3fcb26f4bc4c1dece0089e90cb645ee Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Fri, 12 Jun 2026 18:21:51 +0200 Subject: osc: kitty text-size: bail out if text is zero-length This fixes a crash further down, where we try to lookup an existing compose sequence. Closes #2364 --- osc.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'osc.c') diff --git a/osc.c b/osc.c index 95af5bff..05281d0e 100644 --- a/osc.c +++ b/osc.c @@ -1149,6 +1149,9 @@ kitty_text_size(struct terminal *term, char *string) *text = '\0'; text++; + if (text[0] == '\0') + return; + char32_t *wchars = ambstoc32(text); if (wchars == NULL) return; -- cgit v1.3