os/fs: Rename os_file_exists to os_path_exists (#4973)

Because the old name did not indicate that the function
would return true on directories as well.
This commit is contained in:
Daniel Xu
2016-07-05 22:40:25 -07:00
committed by Justin M. Keyes
parent bd6dad06dd
commit 5f1a153831
16 changed files with 93 additions and 73 deletions

View File

@@ -1359,7 +1359,7 @@ recover_names (
if (*dirp == NUL && file_count + num_files == 0 && fname != NULL) {
char_u *swapname = (char_u *)modname((char *)fname_res, ".swp", TRUE);
if (swapname != NULL) {
if (os_file_exists(swapname)) {
if (os_path_exists(swapname)) {
files = xmalloc(sizeof(char_u *));
files[0] = swapname;
swapname = NULL;
@@ -3426,11 +3426,11 @@ static char *findswapname(buf_T *buf, char **dirp, char *old_fname,
break;
}
/* If the file was deleted this fname can be used. */
if (!os_file_exists((char_u *) fname))
// If the file was deleted this fname can be used.
if (!os_path_exists((char_u *)fname)) {
break;
} else
{
}
} else {
MSG_PUTS("\n");
if (msg_silent == 0)
/* call wait_return() later */