1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* ext/nkf/nkf-utf8/nkf.c (struct input_code.name, input_codename):

constified.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2008-07-22 18:19:34 +00:00
parent 5c0dcf52fd
commit e35550c3e7
2 changed files with 11 additions and 6 deletions

View file

@ -1,3 +1,8 @@
Wed Jul 23 03:19:31 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
* ext/nkf/nkf-utf8/nkf.c (struct input_code.name, input_codename):
constified.
Wed Jul 23 03:02:08 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
* ext/syck: suppress warnings.

View file

@ -318,7 +318,7 @@ extern POINT _BufferSize;
#endif
struct input_code{
char *name;
const char *name;
nkf_char stat;
nkf_char score;
nkf_char index;
@ -328,7 +328,7 @@ struct input_code{
int _file_stat;
};
static char *input_codename = NULL; /* NULL: unestablished, "": BINARY */
static const char *input_codename = NULL; /* NULL: unestablished, "": BINARY */
static nkf_encoding *input_encoding = NULL;
static nkf_encoding *output_encoding = NULL;
@ -439,7 +439,7 @@ static nkf_char (*iconv_for_check)(nkf_char c2,nkf_char c1,nkf_char c0) = 0;
#endif
static int guess_f = 0; /* 0: OFF, 1: ON, 2: VERBOSE */
static void set_input_codename(char *codename);
static void set_input_codename(const char *codename);
#ifdef EXEC_IO
static int exec_f = 0;
@ -3499,7 +3499,7 @@ z_conv(nkf_char c2, nkf_char c1)
if (alpha_f&8 && c2 == 0) {
/* HTML Entity */
char *entity = 0;
const char *entity = 0;
switch (c1){
case '>': entity = "&gt;"; break;
case '<': entity = "&lt;"; break;
@ -3982,7 +3982,7 @@ debug(const char *str)
#endif
static void
set_input_codename(char *codename)
set_input_codename(const char *codename)
{
if (!input_codename) {
input_codename = codename;
@ -3991,7 +3991,7 @@ set_input_codename(char *codename)
}
}
static char*
static const char*
get_guessed_code(void)
{
if (input_codename && !*input_codename) {