Skip to content

Commit

Permalink
patch 8.2.3947: unnecessary check for NULL pointer
Browse files Browse the repository at this point in the history
Problem:    Unnecessary check for NULL pointer.
Solution:   Remove the check. (closes #9434)
  • Loading branch information
zeertzjq authored and brammool committed Dec 30, 2021
1 parent 1c67f3a commit f38aad8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ex_docmd.c
Expand Up @@ -7411,9 +7411,9 @@ changedir_func(
# endif
new_dir = NameBuff;
}
dir_differs = new_dir == NULL || pdir == NULL
dir_differs = pdir == NULL
|| pathcmp((char *)pdir, (char *)new_dir, -1) != 0;
if (new_dir == NULL || (dir_differs && vim_chdir(new_dir)))
if (dir_differs && vim_chdir(new_dir))
{
emsg(_(e_failed));
vim_free(pdir);
Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Expand Up @@ -749,6 +749,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
3947,
/**/
3946,
/**/
Expand Down

0 comments on commit f38aad8

Please sign in to comment.