0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

patch 8.1.2003: MS-Windows: code page 65001 is not recognized

Problem:    MS-Windows: code page 65001 is not recognized.
Solution:   Use utf-8 for code page 65001. (Dan Thompson, closes #4902)
This commit is contained in:
Bram Moolenaar
2019-09-07 16:07:47 +02:00
parent 9b1cd65d8b
commit fa90d70884
2 changed files with 5 additions and 1 deletions

View File

@@ -4468,8 +4468,10 @@ enc_locale(void)
if (acp == 1200)
STRCPY(buf, "ucs-2le");
else if (acp == 1252) /* cp1252 is used as latin1 */
else if (acp == 1252) // cp1252 is used as latin1
STRCPY(buf, "latin1");
else if (acp == 65001)
STRCPY(buf, "utf-8");
else
sprintf(buf, "cp%ld", acp);