mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
add IO#sync and IO#sync=
This commit is contained in:
@@ -13,14 +13,14 @@ struct mrb_io {
|
||||
int fd; /* file descriptor, or -1 */
|
||||
int fd2; /* file descriptor to write if it's different from fd, or -1 */
|
||||
int pid; /* child's pid (for pipes) */
|
||||
unsigned int writable:1;
|
||||
unsigned int writable:1,
|
||||
sync:1;
|
||||
};
|
||||
|
||||
#define FMODE_READABLE 0x00000001
|
||||
#define FMODE_WRITABLE 0x00000002
|
||||
#define FMODE_READWRITE (FMODE_READABLE|FMODE_WRITABLE)
|
||||
#define FMODE_BINMODE 0x00000004
|
||||
#define FMODE_SYNC 0x00000008
|
||||
#define FMODE_APPEND 0x00000040
|
||||
#define FMODE_CREATE 0x00000080
|
||||
#define FMODE_TRUNC 0x00000800
|
||||
|
||||
Reference in New Issue
Block a user