From 86a0891952f8cd83138bc2b6fe760190c67c8ff9 Mon Sep 17 00:00:00 2001 From: Oliver Kiddle Date: Thu, 30 Jan 2025 12:41:53 +0100 Subject: 53335: Remove unused dupstring_glen() function Also make use of the dupstring_wlen() variant in more places to avoid a strlen() --- Src/Zle/compctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Src/Zle/compctl.c') diff --git a/Src/Zle/compctl.c b/Src/Zle/compctl.c index 08355d1b9..de3ccdfce 100644 --- a/Src/Zle/compctl.c +++ b/Src/Zle/compctl.c @@ -3201,8 +3201,8 @@ makecomplistflags(Compctl cc, char *s, int incmd, int compadd) memcpy(lpre, s, lpl); lpre[lpl] = '\0'; qlpre = quotename(lpre); - lsuf = dupstring(s + offs); - lsl = strlen(lsuf); + lsl = strlen(s + offs); + lsuf = dupstring_wlen(s + offs, lsl); qlsuf = quotename(lsuf); /* First check for ~.../... */ -- cgit v1.2.3