From 3a8432437934a0a95f2618b534b1f5b3494d6b18 Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Mon, 1 Apr 2013 17:11:14 +0200 Subject: =?UTF-8?q?Ma=C5=95k=20cgit=5Fenvironment=20members=20const?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit These reflect the values of environment variables and should never be changed. Add another xstrdup() when we assign environment variables to strings that are potentially non-constant. Signed-off-by: Lukas Fleischer --- cgit.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'cgit.h') diff --git a/cgit.h b/cgit.h index ed5cf14..081f669 100644 --- a/cgit.h +++ b/cgit.h @@ -255,16 +255,16 @@ struct cgit_page { }; struct cgit_environment { - char *cgit_config; - char *http_host; - char *https; - char *no_http; - char *path_info; - char *query_string; - char *request_method; - char *script_name; - char *server_name; - char *server_port; + const char *cgit_config; + const char *http_host; + const char *https; + const char *no_http; + const char *path_info; + const char *query_string; + const char *request_method; + const char *script_name; + const char *server_name; + const char *server_port; }; struct cgit_context { -- cgit v1.2.1