From 20e2a5c111f488a53233fd3765dbc7f8e4a3e2b3 Mon Sep 17 00:00:00 2001 From: Brian Gianforcaro Date: Sun, 9 Aug 2020 15:37:45 -0700 Subject: [PATCH] Kernel: Use Userspace for the module_unload syscall --- Kernel/Process.h | 2 +- Kernel/Syscalls/module.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Kernel/Process.h b/Kernel/Process.h index 9171c68d58..195ac60f4e 100644 --- a/Kernel/Process.h +++ b/Kernel/Process.h @@ -326,7 +326,7 @@ public: ssize_t sys$getrandom(Userspace, size_t, unsigned int); int sys$setkeymap(Userspace); int sys$module_load(Userspace path, size_t path_length); - int sys$module_unload(const char* name, size_t name_length); + int sys$module_unload(Userspace name, size_t name_length); int sys$profiling_enable(pid_t); int sys$profiling_disable(pid_t); int sys$futex(Userspace); diff --git a/Kernel/Syscalls/module.cpp b/Kernel/Syscalls/module.cpp index 46dcc80ef9..5d3617244c 100644 --- a/Kernel/Syscalls/module.cpp +++ b/Kernel/Syscalls/module.cpp @@ -163,7 +163,7 @@ int Process::sys$module_load(Userspace user_path, size_t path_lengt return 0; } -int Process::sys$module_unload(const char* user_name, size_t name_length) +int Process::sys$module_unload(Userspace user_name, size_t name_length) { if (!is_superuser()) return -EPERM;