diff options
-rw-r--r-- | ext/mbstring/mbstring.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index a15aa98209..90d8a9d8c8 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -95,7 +95,7 @@ static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { }; #endif -#if defined(HAVE_MBSTR_TW) & !defined(HAVE_MBSTR_JA) +#if defined(HAVE_MBSTR_TW) & !defined(HAVE_MBSTR_CN) & !defined(HAVE_MBSTR_JA) static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { mbfl_no_encoding_ascii, mbfl_no_encoding_utf8, @@ -104,7 +104,7 @@ static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { }; #endif -#if defined(HAVE_MBSTR_KR) & !defined(HAVE_MBSTR_JA) +#if defined(HAVE_MBSTR_KR) & !defined(HAVE_MBSTR_TW) & !defined(HAVE_MBSTR_CN) & !defined(HAVE_MBSTR_JA) static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { mbfl_no_encoding_ascii, mbfl_no_encoding_utf8, @@ -113,7 +113,7 @@ static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { }; #endif -#if defined(HAVE_MBSTR_RU) & !defined(HAVE_MBSTR_JA) & !defined(HAVE_MBSTR_TW) & !defined(HAVE_MBSTR_KR) +#if defined(HAVE_MBSTR_RU) & !defined(HAVE_MBSTR_KR) & !defined(HAVE_MBSTR_TW) & !defined(HAVE_MBSTR_CN) & !defined(HAVE_MBSTR_JA) static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { mbfl_no_encoding_ascii, mbfl_no_encoding_utf8, @@ -123,6 +123,13 @@ static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { }; #endif +#if !defined(HAVE_MBSTR_RU) & !defined(HAVE_MBSTR_KR) & !defined(HAVE_MBSTR_TW) & !defined(HAVE_MBSTR_CN) & !defined(HAVE_MBSTR_JA) +static const enum mbfl_no_encoding php_mbstr_default_identify_list[] = { + mbfl_no_encoding_ascii, + mbfl_no_encoding_utf8 +}; +#endif + static const int php_mbstr_default_identify_list_size = sizeof(php_mbstr_default_identify_list)/sizeof(enum mbfl_no_encoding); static unsigned char third_and_rest_force_ref[] = { 3, BYREF_NONE, BYREF_NONE, BYREF_FORCE_REST }; |