fs/vfs/fs_ioctl.c: Add FIOCLEX/FIONCLEX support

This commit is contained in:
Yoshinori Sugino
2020-09-16 14:04:20 +09:00
committed by Xiang Xiao
parent 6584bfa361
commit d4ec1ababd
2 changed files with 12 additions and 0 deletions
+6
View File
@@ -194,6 +194,12 @@ int nx_vioctl(int fd, int req, va_list ap)
nx_fcntl(fd, F_GETFL) & ~O_NONBLOCK);
}
break;
case FIOCLEX:
ret = nx_fcntl(fd, F_SETFD, FD_CLOEXEC);
break;
case FIONCLEX:
ret = nx_fcntl(fd, F_SETFD, 0);
break;
}
}