From: Bruno Haible Date: Mon, 30 Apr 2001 11:25:15 +0000 (+0000) Subject: Silence a gcc warning. X-Git-Tag: v0.11~758 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3622cd8108ba5caf2e3332640e50e342caa7d91b;p=thirdparty%2Fgettext.git Silence a gcc warning. --- diff --git a/intl/ChangeLog b/intl/ChangeLog index 7e76a1579..d47b754c7 100644 --- a/intl/ChangeLog +++ b/intl/ChangeLog @@ -1,3 +1,9 @@ +2001-04-30 Bruno Haible + + Silence "gcc -Wall -Wwrite-strings" warnings. + * localcharset.c (charset_aliases): Change type to 'const char *'. + (get_charset_aliases): Change type of 'cp' to 'const char *'. + 2001-04-19 Bruno Haible * gettext-0.10.37 released. diff --git a/intl/localcharset.c b/intl/localcharset.c index 22e09e410..61f8f3e85 100644 --- a/intl/localcharset.c +++ b/intl/localcharset.c @@ -75,13 +75,13 @@ /* Pointer to the contents of the charset.alias file, if it has already been read, else NULL. Its format is: ALIAS_1 '\0' CANONICAL_1 '\0' ... ALIAS_n '\0' CANONICAL_n '\0' '\0' */ -static char * volatile charset_aliases; +static const char * volatile charset_aliases; /* Return a pointer to the contents of the charset.alias file. */ static const char * get_charset_aliases () { - char *cp; + const char *cp; cp = charset_aliases; if (cp == NULL) diff --git a/lib/ChangeLog b/lib/ChangeLog index 58fcffa6a..97ba8fc99 100644 --- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,9 @@ +2001-04-30 Bruno Haible + + Silence "gcc -Wall -Wwrite-strings" warnings. + * localcharset.c (charset_aliases): Change type to 'const char *'. + (get_charset_aliases): Change type of 'cp' to 'const char *'. + 2001-04-19 Bruno Haible * gettext-0.10.37 released. diff --git a/lib/localcharset.c b/lib/localcharset.c index 22e09e410..61f8f3e85 100644 --- a/lib/localcharset.c +++ b/lib/localcharset.c @@ -75,13 +75,13 @@ /* Pointer to the contents of the charset.alias file, if it has already been read, else NULL. Its format is: ALIAS_1 '\0' CANONICAL_1 '\0' ... ALIAS_n '\0' CANONICAL_n '\0' '\0' */ -static char * volatile charset_aliases; +static const char * volatile charset_aliases; /* Return a pointer to the contents of the charset.alias file. */ static const char * get_charset_aliases () { - char *cp; + const char *cp; cp = charset_aliases; if (cp == NULL)