Blob Blame History Raw
diff --git a/htcommon/cgi.cc b/htcommon/cgi.cc
index 557d90e..11e3187 100644
--- a/htcommon/cgi.cc
+++ b/htcommon/cgi.cc
@@ -54,7 +54,7 @@ cgi::cgi()
 //*****************************************************************************
 // cgi::cgi(char *s)
 //
-cgi::cgi(char *s)
+cgi::cgi(const char *s)
 {
 	init(s);
 }
@@ -64,7 +64,7 @@ cgi::cgi(char *s)
 // void cgi::init(char *s)
 //
 void
-cgi::init(char *s)
+cgi::init(const char *s)
 {
 	pairs = new Dictionary;
 
@@ -153,7 +153,7 @@ cgi::~cgi()
 //*****************************************************************************
 // char *cgi::operator [] (char *name)
 //
-char *cgi::operator [] (char *name)
+char *cgi::operator [] (const char *name)
 {
 	return get(name);
 }
@@ -162,7 +162,7 @@ char *cgi::operator [] (char *name)
 //*****************************************************************************
 // char *cgi::get(char *name)
 //
-char *cgi::get(char *name)
+char *cgi::get(const char *name)
 {
 	String	*str = (String *) (*pairs)[name];
 	if (str)
@@ -187,7 +187,7 @@ char *cgi::get(char *name)
 // int cgi::exists(char *name)
 //
 int
-cgi::exists(char *name)
+cgi::exists(const char *name)
 {
 	return pairs->Exists(name);
 }
diff --git a/htcommon/cgi.h b/htcommon/cgi.h
index c1232f0..91cdbb6 100644
--- a/htcommon/cgi.h
+++ b/htcommon/cgi.h
@@ -21,18 +21,18 @@ class cgi
 {
 public:
 	cgi();
-	cgi(char *s);
+	cgi(const char *s);
 	~cgi();
 
-	char			*operator [] (char *);
-	char			*get(char *);
-	int			exists(char *);
+	char			*operator [] (const char *);
+	char			*get(const char *);
+	int			exists(const char *);
 	char			*path();
 
 private:
 	Dictionary		*pairs;
 	int			query;
-	void			init(char *s);
+	void			init(const char *s);
 };
 
 #endif
diff --git a/htdig/htdig.cc b/htdig/htdig.cc
index ba1d842..dfd5177 100644
--- a/htdig/htdig.cc
+++ b/htdig/htdig.cc
@@ -82,7 +82,7 @@ int main(int ac, char **av)
     int			initial = 0;
     int			alt_work_area = 0;
     int			create_text_database = 0;
-    char		*max_hops = 0;
+    const char		*max_hops = 0;
 
     // Cookie jar dynamic creation.
     HtCookieJar*        _cookie_jar = new HtCookieMemJar(); // new cookie jar
@@ -157,14 +157,14 @@ int main(int ac, char **av)
     // Warn user if any obsolete options are found in config file
     // For efficiency, check all fields here.  If different config
     // files are used for searching, obsolete options may remain
-    char *deprecatedOptions [] = {
+    const char *deprecatedOptions [] = {
 	"heading_factor_1", "heading_factor_2", "heading_factor_3",
 	"heading_factor_4", "heading_factor_5", "heading_factor_6",
 	"modification_time_is_now", "pdf_parser", "translate_amp",
 	"translate_lt_gt", "translate_quot", "uncoded_db_compatible",
 	""	// empty terminator
     };
-    char **option;
+    const char **option;
     for (option = deprecatedOptions; **option; option++)
     {
 	if (!config->Find(*option).empty())
diff --git a/htlib/Configuration.h b/htlib/Configuration.h
index 2628617..822fe24 100644
--- a/htlib/Configuration.h
+++ b/htlib/Configuration.h
@@ -109,15 +109,15 @@
 
 struct ConfigDefaults
 {
-  char	*name;			// Name of the attribute
+  const char	*name;			// Name of the attribute
   char	*value;			// Default value
-  char	*type;			// Type of the value (string, integer, boolean)
-  char	*programs;		// Whitespace separated list of programs/modules using this attribute
-  char	*block;			// Configuration block this can be used in (can be blank)
-  char	*version;		// Version that introduced the attribute
-  char	*category;		// Attribute category (to split documentation)
-  char	*example;		// Example usage of the attribute (HTML)
-  char	*description;		// Long description of the attribute (HTML)
+  const char	*type;			// Type of the value (string, integer, boolean)
+  const char	*programs;		// Whitespace separated list of programs/modules using this attribute
+  const char	*block;			// Configuration block this can be used in (can be blank)
+  const char	*version;		// Version that introduced the attribute
+  const char	*category;		// Attribute category (to split documentation)
+  const char	*example;		// Example usage of the attribute (HTML)
+  const char	*description;		// Long description of the attribute (HTML)
 };
 
 
diff --git a/htlib/strptime.cc b/htlib/strptime.cc
index 5cd2875..c858d1a 100644
--- a/htlib/strptime.cc
+++ b/htlib/strptime.cc
@@ -55,16 +55,16 @@ static char sccsid[] = "@(#)strptime.c	1.0 (Powerdog) 94/03/27";
 #define asizeof(a)	((int)(sizeof (a) / sizeof ((a)[0])))
 
 struct mydtconv {
-    char	*abbrev_month_names[12];
-    char	*month_names[12];
-    char	*abbrev_weekday_names[7];
-    char	*weekday_names[7];
-    char	*time_format;
-    char	*sdate_format;
-    char	*dtime_format;
-    char	*am_string;
-    char	*pm_string;
-    char	*ldate_format;
+    const char	*abbrev_month_names[12];
+    const char	*month_names[12];
+    const char	*abbrev_weekday_names[7];
+    const char	*weekday_names[7];
+    const char	*time_format;
+    const char	*sdate_format;
+    const char	*dtime_format;
+    const char	*am_string;
+    const char	*pm_string;
+    const char	*ldate_format;
 };
 
 static struct mydtconv	En_US = {
diff --git a/htword/WordMonitor.cc b/htword/WordMonitor.cc
index d5f342f..6e9ed35 100644
--- a/htword/WordMonitor.cc
+++ b/htword/WordMonitor.cc
@@ -29,7 +29,7 @@
 
 WordMonitor* WordMonitor::instance = 0;
 
-char* WordMonitor::values_names[WORD_MONITOR_VALUES_SIZE] = {
+const char* WordMonitor::values_names[WORD_MONITOR_VALUES_SIZE] = {
   "",
   "C.Write",
   "C.Read",
diff --git a/htword/WordMonitor.h b/htword/WordMonitor.h
index c1ce3c7..0f29fc8 100644
--- a/htword/WordMonitor.h
+++ b/htword/WordMonitor.h
@@ -127,7 +127,7 @@ class WordMonitor {
     int period;
     FILE* output;
     int output_style;
-    static char* values_names[WORD_MONITOR_VALUES_SIZE];
+    static const char* values_names[WORD_MONITOR_VALUES_SIZE];
 
     //
     // Unique instance pointer