From 98affe1115dfdab932432c09160f46ca3d269fb7 Mon Sep 17 00:00:00 2001 From: Jörg Sommer Date: Mon, 1 Jan 2024 19:10:18 +0100 Subject: 52441: zle_vi: Mark variables with const init as const Because these variables are initialized with as constant string, they should be marked as *const* to make the compiler running with `-Wwrite-strings` more happy. --- ChangeLog | 2 ++ Src/Zle/zle_vi.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 22875c7e9..16e012d5b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 2024-01-28 Oliver Kiddle + * Jörg Sommer: 52441: Src/Zle/zle_vi.c: Mark variables as const + * Jörg Sommer: 52440: Src/Zle/textobjects.c: Mark variables as const 2024-01-26 Oliver Kiddle diff --git a/Src/Zle/zle_vi.c b/Src/Zle/zle_vi.c index 24d9de6ea..6692df830 100644 --- a/Src/Zle/zle_vi.c +++ b/Src/Zle/zle_vi.c @@ -1014,7 +1014,7 @@ int visetbuffer(char **args) { ZLE_INT_T ch; - ZLE_CHAR_T *match = ZWS("_*+"); + const ZLE_CHAR_T *match = ZWS("_*+"); int registermod[] = { MOD_NULL, MOD_PRI, MOD_CLIP }; ZLE_CHAR_T *found; -- cgit v1.3.1