Change max byte length of UTF-8 to 4 bytes

In enc/utf_8.c, change maximum byte length of UTF-8 to 4 bytes (from 6)
to conform to definition of UTF-8. This closes issue #13590.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58954 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
duerst 2017-05-29 08:41:23 +00:00
Родитель 83ddb7c182
Коммит a03690ae73
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -417,7 +417,7 @@ get_case_fold_codes_by_str(OnigCaseFoldType flag,
OnigEncodingDefine(utf_8, UTF_8) = {
mbc_enc_len,
"UTF-8", /* name */
6, /* max byte length */
4, /* max byte length */
1, /* min byte length */
is_mbc_newline,
mbc_to_code,