From d17a289e9835fe04b79f1957b3d513b519ab307c Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sun, 27 Sep 2026 19:07:17 -1000 Subject: Keep string literals behind const pointers Git's DEVELOPER=1 build turns on -Wwrite-strings as an error, and the literals stored through plain char pointers failed cgit's own objects there. The exec filter's argv takes the cast execvp needs once, the way git's run-command does. --- source/shared.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/shared.c') diff --git a/source/shared.c b/source/shared.c index a5c54ee..a6a5106 100644 --- a/source/shared.c +++ b/source/shared.c @@ -24,7 +24,7 @@ typedef struct { struct cgit_repolist cgit_repolist; struct cgit_context ctx; -char *cgit_default_repo_desc = "[no description]"; +char cgit_default_repo_desc[] = "[no description]"; // A diff line that arrived in pieces and is still waiting for its end, see // emit_line. -- cgit 2.12.1