F_SETFL is not implemented on nt

This commit is contained in:
Gavin Hayes 2022-10-17 14:25:33 -04:00
parent 8b4991b2db
commit e046530eb6

View file

@ -140,7 +140,7 @@ textwindows int sys_fcntl_nt(int fd, int cmd, uintptr_t arg) {
// O_DSYNC / O_RSYNC / O_SYNC maybe if we fsync() everything // O_DSYNC / O_RSYNC / O_SYNC maybe if we fsync() everything
// O_DIRECT | O_RANDOM | O_SEQUENTIAL | O_NDELAY possible but // O_DIRECT | O_RANDOM | O_SEQUENTIAL | O_NDELAY possible but
// not worth it. // not worth it.
return einval(); return enosys();
} else if (cmd == F_GETFD) { } else if (cmd == F_GETFD) {
if (g_fds.p[fd].flags & O_CLOEXEC) { if (g_fds.p[fd].flags & O_CLOEXEC) {
return FD_CLOEXEC; return FD_CLOEXEC;