1
0
forked from aniani/vim

patch 8.0.1496: clearing a pointer takes two lines

Problem:    Clearing a pointer takes two lines.
Solution:   Add VIM_CLEAR() and replace vim_clear(). (Hirohito Higashi,
            closes #2629)
This commit is contained in:
Bram Moolenaar
2018-02-10 18:45:26 +01:00
parent 42443c7d7f
commit d23a823669
54 changed files with 233 additions and 465 deletions

View File

@@ -371,7 +371,7 @@ mch_chdir(char *path)
#endif
/*
* Write s[len] to the screen.
* Write s[len] to the screen (stdout).
*/
void
mch_write(char_u *s, int len)
@@ -1311,8 +1311,7 @@ mch_suspend(void)
/*
* Set oldtitle to NULL, so the current title is obtained again.
*/
vim_free(oldtitle);
oldtitle = NULL;
VIM_CLEAR(oldtitle);
# endif
settmode(TMODE_RAW);
need_check_timestamps = TRUE;
@@ -3261,8 +3260,7 @@ mch_free_mem(void)
XCloseDisplay(x11_display);
# endif
# if defined(HAVE_SIGALTSTACK) || defined(HAVE_SIGSTACK)
vim_free(signal_stack);
signal_stack = NULL;
VIM_CLEAR(signal_stack);
# endif
# ifdef FEAT_TITLE
vim_free(oldtitle);
@@ -6765,8 +6763,7 @@ mch_expand_wildcards(
if (*num_file == 0) /* rejected all entries */
{
vim_free(*file);
*file = NULL;
VIM_CLEAR(*file);
goto notfound;
}