vim-patch:9.0.1215: using isalpha() adds dependency on current locale

Problem:    Using isalpha() adds dependency on current locale.
Solution:   Do not use isalpha() for recognizing a URL or the end of an Ex
            command. (closes vim/vim#11835)

0ef9a5c094
This commit is contained in:
zeertzjq
2023-01-18 06:27:45 +08:00
parent 8c344378b8
commit 9a2dd52a6a
3 changed files with 4 additions and 4 deletions

View File

@@ -2852,7 +2852,7 @@ bool checkforcmd(char **pp, const char *cmd, int len)
break;
}
}
if (i >= len && !isalpha((uint8_t)(*pp)[i])) {
if (i >= len && !ASCII_ISALPHA((*pp)[i])) {
*pp = skipwhite(*pp + i);
return true;
}