kernel: usercopy functions

This commit is contained in:
Matheus
2024-06-09 19:31:26 -03:00
parent 429f56aced
commit 50b4b45d00
53 changed files with 712 additions and 260 deletions
+5
View File
@@ -7,6 +7,11 @@ syscallret_t syscall_ioctl(context_t *, int fd, unsigned long request, void *arg
.ret = -1
};
if (IS_USER_ADDRESS(arg) == false) {
ret.errno = EFAULT;
return ret;
}
file_t *file = fd_get(fd);
if (file == NULL) {
ret.errno = EBADF;