diff options
Diffstat (limited to 'src/nvim/os/fileio.h')
-rw-r--r-- | src/nvim/os/fileio.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nvim/os/fileio.h b/src/nvim/os/fileio.h index 2cffd5c851..7c53cd4f07 100644 --- a/src/nvim/os/fileio.h +++ b/src/nvim/os/fileio.h @@ -14,6 +14,7 @@ typedef struct { RBuffer *rv; ///< Read or write buffer. bool wr; ///< True if file is in write mode. bool eof; ///< True if end of file was encountered. + bool non_blocking; ///< True if EAGAIN should not restart syscalls. } FileDescriptor; /// file_open() flags @@ -30,6 +31,10 @@ typedef enum { kFileTruncate = 32, ///< Truncate the file if it exists. ///< Implies kFileWriteOnly. Cannot be used with ///< kFileCreateOnly. + kFileAppend = 64, ///< Append to the file. Implies kFileWriteOnly. Cannot + ///< be used with kFileCreateOnly. + kFileNonBlocking = 128, ///< Do not restart read() or write() syscall if + ///< EAGAIN was encountered. } FileOpenFlags; static inline bool file_eof(const FileDescriptor *const fp) |