ctype: make sane_ctype[] const array

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Nguyễn Thái Ngọc Duy committed Oct 15, 2012 at 13:25 UTC ca5ab7d1e813435bbf4ba0615a2adf0cdc35960e
2 files changed +2 -2
ctype.c
+1 -1
@@ -14,7 +14,7 @@ enum {
14 P = GIT_PATHSPEC_MAGIC /* other non-alnum, except for ] and } */
15 };
16
17 -unsigned char sane_ctype[256] = {
17 +const unsigned char sane_ctype[256] = {
18 0, 0, 0, 0, 0, 0, 0, 0, 0, S, S, 0, 0, S, 0, 0, /* 0.. 15 */
19 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 16.. 31 */
20 S, P, P, P, R, P, P, P, R, R, G, R, P, P, R, P, /* 32.. 47 */
git-compat-util.h
+1 -1
@@ -470,7 +470,7 @@ extern const char tolower_trans_tbl[256];
470 #undef isupper
471 #undef tolower
472 #undef toupper
473 -extern unsigned char sane_ctype[256];
473 +extern const unsigned char sane_ctype[256];
474 #define GIT_SPACE 0x01
475 #define GIT_DIGIT 0x02
476 #define GIT_ALPHA 0x04