refactor: replace char_u with char

Work on https://github.com/neovim/neovim/issues/459
This commit is contained in:
Dundar Göc
2022-08-26 23:11:25 +02:00
committed by dundargoc
parent 82d93429e7
commit 684bc749ef
39 changed files with 262 additions and 275 deletions

View File

@@ -2836,12 +2836,12 @@ static void append_command(char *cmd)
}
STRCAT(IObuff, ": ");
d = (char *)IObuff + STRLEN(IObuff);
while (*s != NUL && (char_u *)d - IObuff + 5 < IOSIZE) {
while (*s != NUL && d - IObuff + 5 < IOSIZE) {
if ((char_u)s[0] == 0xc2 && (char_u)s[1] == 0xa0) {
s += 2;
STRCPY(d, "<a0>");
d += 4;
} else if ((char_u *)d - IObuff + utfc_ptr2len(s) + 1 >= IOSIZE) {
} else if (d - IObuff + utfc_ptr2len(s) + 1 >= IOSIZE) {
break;
} else {
mb_copy_char((const char **)&s, &d);