diff options
author | bfredl <bjorn.linse@gmail.com> | 2022-08-29 12:50:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-29 12:50:22 +0200 |
commit | 5fe6bde296569e275a0b83d497a54611f73c410a (patch) | |
tree | 51931728be1890c53597595aeec0826b12b74202 /src/nvim/ex_docmd.c | |
parent | f05cc672e3b617b4480d8e2d7efc7e00863efc3d (diff) | |
parent | 691f4715c0cf4bc11ea2280db8777e6dd174a8ac (diff) | |
download | rneovim-5fe6bde296569e275a0b83d497a54611f73c410a.tar.gz rneovim-5fe6bde296569e275a0b83d497a54611f73c410a.tar.bz2 rneovim-5fe6bde296569e275a0b83d497a54611f73c410a.zip |
Merge pull request #19961 from dundargoc/refactor/char_u/2
refactor: replace char_u with char 2: electric chaaralo
Diffstat (limited to 'src/nvim/ex_docmd.c')
-rw-r--r-- | src/nvim/ex_docmd.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/nvim/ex_docmd.c b/src/nvim/ex_docmd.c index 8cf5d56dd7..5b38118a33 100644 --- a/src/nvim/ex_docmd.c +++ b/src/nvim/ex_docmd.c @@ -531,7 +531,7 @@ int do_cmdline(char *cmdline, LineGetter fgetline, void *cookie, int flags) if (flags & DOCMD_KEEPLINE) { xfree(repeat_cmdline); if (count == 0) { - repeat_cmdline = vim_strsave((char_u *)next_cmdline); + repeat_cmdline = (char *)vim_strsave((char_u *)next_cmdline); } else { repeat_cmdline = NULL; } @@ -3791,8 +3791,8 @@ int expand_filename(exarg_T *eap, char **cmdlinep, char **errormsgp) // if there are still wildcards present. if (vim_strchr(eap->arg, '$') != NULL || vim_strchr(eap->arg, '~') != NULL) { - expand_env_esc((char_u *)eap->arg, NameBuff, MAXPATHL, true, true, NULL); - has_wildcards = path_has_wildcard(NameBuff); + expand_env_esc((char_u *)eap->arg, (char_u *)NameBuff, MAXPATHL, true, true, NULL); + has_wildcards = path_has_wildcard((char_u *)NameBuff); p = (char *)NameBuff; } else { p = NULL; @@ -4061,7 +4061,7 @@ static int getargopt(exarg_T *eap) *arg = NUL; if (pp == &eap->force_ff) { - if (check_ff_value((char_u *)eap->cmd + eap->force_ff) == FAIL) { + if (check_ff_value(eap->cmd + eap->force_ff) == FAIL) { return FAIL; } eap->force_ff = (char_u)eap->cmd[eap->force_ff]; @@ -5485,8 +5485,8 @@ bool changedir_func(char *new_dir, CdScope scope) new_dir = pdir; } - if (os_dirname(NameBuff, MAXPATHL) == OK) { - pdir = (char *)vim_strsave(NameBuff); + if (os_dirname((char_u *)NameBuff, MAXPATHL) == OK) { + pdir = xstrdup(NameBuff); } else { pdir = NULL; } @@ -5499,7 +5499,7 @@ bool changedir_func(char *new_dir, CdScope scope) if (*new_dir == NUL && p_cdh) { #endif // Use NameBuff for home directory name. - expand_env((char_u *)"$HOME", NameBuff, MAXPATHL); + expand_env((char_u *)"$HOME", (char_u *)NameBuff, MAXPATHL); new_dir = (char *)NameBuff; } @@ -5568,7 +5568,7 @@ void ex_cd(exarg_T *eap) /// ":pwd". static void ex_pwd(exarg_T *eap) { - if (os_dirname(NameBuff, MAXPATHL) == OK) { + if (os_dirname((char_u *)NameBuff, MAXPATHL) == OK) { #ifdef BACKSLASH_IN_FILENAME slash_adjust(NameBuff); #endif |