From 4ce9d9ee225997cb134a854274787d3f5c30dd1f Mon Sep 17 00:00:00 2001 From: Andrea Mazzoleni Date: Mon, 6 Jul 2026 18:11:43 +0200 Subject: [PATCH] Fix strtrim to correctly trim strings containing only whitespace --- cmdline/support.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmdline/support.c b/cmdline/support.c index 3e2d122e..e6ab9655 100644 --- a/cmdline/support.c +++ b/cmdline/support.c @@ -1140,7 +1140,7 @@ char* strtrim(char* str) end[0] = 0; - if (begin != end) + if (begin != str) memmove(str, begin, end - begin + 1); return str;