|
void | fs_init (void) |
|
void | fs_loop_lock (void) |
|
void | fs_loop_unlock (void) |
|
int | os_chdir (const char *path) FUNC_ATTR_NONNULL_ALL |
|
int | os_dirname (char_u *buf, size_t len) FUNC_ATTR_NONNULL_ALL |
|
bool | os_isrealdir (const char *name) FUNC_ATTR_NONNULL_ALL |
|
bool | os_isdir (const char_u *name) FUNC_ATTR_NONNULL_ALL |
|
bool | os_isdir_executable (const char *name) FUNC_ATTR_NONNULL_ALL |
|
int | os_nodetype (const char *name) FUNC_ATTR_NONNULL_ALL |
|
int | os_exepath (char *buffer, size_t *size) FUNC_ATTR_NONNULL_ALL |
|
bool | os_can_exe (const char *name, char **abspath, bool use_path) FUNC_ATTR_NONNULL_ARG(1) |
|
int | os_open (const char *path, int flags, int mode) |
|
FILE * | os_fopen (const char *path, const char *flags) |
|
int | os_set_cloexec (const int fd) |
| Sets file descriptor fd to close-on-exec. More...
|
|
int | os_close (const int fd) |
|
int | os_dup (const int fd) FUNC_ATTR_WARN_UNUSED_RESULT |
|
ptrdiff_t | os_read (const int fd, bool *const ret_eof, char *const ret_buf, const size_t size, const bool non_blocking) FUNC_ATTR_WARN_UNUSED_RESULT |
|
ptrdiff_t | os_write (const int fd, const char *const buf, const size_t size, const bool non_blocking) FUNC_ATTR_WARN_UNUSED_RESULT |
|
int | os_copy (const char *path, const char *new_path, int flags) |
|
int | os_fsync (int fd) |
|
int32_t | os_getperm (const char *name) |
|
int | os_setperm (const char *const name, int perm) FUNC_ATTR_NONNULL_ALL |
|
int | os_chown (const char *path, uv_uid_t owner, uv_gid_t group) |
|
int | os_fchown (int fd, uv_uid_t owner, uv_gid_t group) |
|
bool | os_path_exists (const char_u *path) |
|
int | os_file_settime (const char *path, double atime, double mtime) |
|
bool | os_file_is_readable (const char *name) FUNC_ATTR_NONNULL_ALL FUNC_ATTR_WARN_UNUSED_RESULT |
|
int | os_file_is_writable (const char *name) FUNC_ATTR_NONNULL_ALL FUNC_ATTR_WARN_UNUSED_RESULT |
|
int | os_rename (const char_u *path, const char_u *new_path) FUNC_ATTR_NONNULL_ALL |
|
int | os_mkdir (const char *path, int32_t mode) FUNC_ATTR_NONNULL_ALL |
|
int | os_mkdir_recurse (const char *const dir, int32_t mode, char **const failed_dir) FUNC_ATTR_NONNULL_ALL FUNC_ATTR_WARN_UNUSED_RESULT |
|
int | os_mkdtemp (const char *template, char *path) FUNC_ATTR_NONNULL_ALL |
|
int | os_rmdir (const char *path) FUNC_ATTR_NONNULL_ALL |
|
bool | os_scandir (Directory *dir, const char *path) FUNC_ATTR_NONNULL_ALL |
|
const char * | os_scandir_next (Directory *dir) FUNC_ATTR_NONNULL_ALL |
|
void | os_closedir (Directory *dir) FUNC_ATTR_NONNULL_ALL |
|
int | os_remove (const char *path) FUNC_ATTR_NONNULL_ALL |
|
bool | os_fileinfo (const char *path, FileInfo *file_info) FUNC_ATTR_NONNULL_ARG(2) |
|
bool | os_fileinfo_link (const char *path, FileInfo *file_info) FUNC_ATTR_NONNULL_ARG(2) |
|
bool | os_fileinfo_fd (int file_descriptor, FileInfo *file_info) FUNC_ATTR_NONNULL_ALL |
|
bool | os_fileinfo_id_equal (const FileInfo *file_info_1, const FileInfo *file_info_2) FUNC_ATTR_NONNULL_ALL |
|
void | os_fileinfo_id (const FileInfo *file_info, FileID *file_id) FUNC_ATTR_NONNULL_ALL |
|
uint64_t | os_fileinfo_inode (const FileInfo *file_info) FUNC_ATTR_NONNULL_ALL |
|
uint64_t | os_fileinfo_size (const FileInfo *file_info) FUNC_ATTR_NONNULL_ALL |
|
uint64_t | os_fileinfo_hardlinks (const FileInfo *file_info) FUNC_ATTR_NONNULL_ALL |
|
uint64_t | os_fileinfo_blocksize (const FileInfo *file_info) FUNC_ATTR_NONNULL_ALL |
|
bool | os_fileid (const char *path, FileID *file_id) FUNC_ATTR_NONNULL_ALL |
|
bool | os_fileid_equal (const FileID *file_id_1, const FileID *file_id_2) FUNC_ATTR_NONNULL_ALL |
|
bool | os_fileid_equal_fileinfo (const FileID *file_id, const FileInfo *file_info) FUNC_ATTR_NONNULL_ALL |
|
char * | os_realpath (const char *name, char *buf) FUNC_ATTR_NONNULL_ARG(1) |
|
int os_open |
( |
const char * |
path, |
|
|
int |
flags, |
|
|
int |
mode |
|
) |
| |
Opens or creates a file and returns a non-negative integer representing the lowest-numbered unused file descriptor, for use in subsequent system calls (read, write, lseek, fcntl, etc.). If the operation fails, a libuv error code is returned, and no file is created or modified.
- Parameters
-
path | Filename |
flags | Bitwise OR of flags defined in <fcntl.h> |
mode | Permissions for the newly-created file (IGNORED if 'flags' is not O_CREAT or O_TMPFILE ), subject to the current umask |
- Returns
- file descriptor, or negative error code on failure