aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2023-02-15 16:45:20 +0000
committerGitHub <noreply@github.com>2023-02-15 16:45:20 +0000
commitf006313e95022340b2b0ae28e8223e6e548f0826 (patch)
tree2bf46d9f1b2c236afacefdafbd3d121023714188 /src/nvim/os
parentec782211f2305382b3a6cb72ab0bbfcab0efcdf0 (diff)
parent6aee2336ca75301bd4db6b99c2392f63f8304335 (diff)
downloadrneovim-f006313e95022340b2b0ae28e8223e6e548f0826.tar.gz
rneovim-f006313e95022340b2b0ae28e8223e6e548f0826.tar.bz2
rneovim-f006313e95022340b2b0ae28e8223e6e548f0826.zip
Merge pull request #22056 from lewis6991/refactor/fileio_more
refactor `fileio.c`
Diffstat (limited to 'src/nvim/os')
-rw-r--r--src/nvim/os/fs.c2
-rw-r--r--src/nvim/os/os_defs.h6
2 files changed, 7 insertions, 1 deletions
diff --git a/src/nvim/os/fs.c b/src/nvim/os/fs.c
index 85d95960a7..7eba5ca54c 100644
--- a/src/nvim/os/fs.c
+++ b/src/nvim/os/fs.c
@@ -783,6 +783,7 @@ int os_setperm(const char *const name, int perm)
# ifdef HAVE_SYS_ACCESS_H
# include <sys/access.h>
# endif
+#endif
// Return a pointer to the ACL of file "fname" in allocated memory.
// Return NULL if the ACL is not available for whatever reason.
@@ -806,7 +807,6 @@ void os_free_acl(vim_acl_T aclent)
return;
}
}
-#endif
#ifdef UNIX
/// Checks if the current user owns a file.
diff --git a/src/nvim/os/os_defs.h b/src/nvim/os/os_defs.h
index a30e16eeba..f86c0d3483 100644
--- a/src/nvim/os/os_defs.h
+++ b/src/nvim/os/os_defs.h
@@ -13,6 +13,12 @@
# include "nvim/os/unix_defs.h"
#endif
+#ifdef BACKSLASH_IN_FILENAME
+# define BACKSLASH_IN_FILENAME_BOOL true
+#else
+# define BACKSLASH_IN_FILENAME_BOOL false
+#endif
+
#if !defined(NAME_MAX) && defined(_XOPEN_NAME_MAX)
# define NAME_MAX _XOPEN_NAME_MAX
#endif