mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-12 11:09:18 +00:00
Kernel: Use Userspace<T> for the chroot syscall
This commit is contained in:
parent
20e2a5c111
commit
e8917cc5f3
Notes:
sideshowbarker
2024-07-19 04:04:33 +09:00
Author: https://github.com/bgianfo
Commit: e8917cc5f3
Pull-request: https://github.com/SerenityOS/serenity/pull/3062
Reviewed-by: https://github.com/awesomekling
2 changed files with 2 additions and 2 deletions
|
@ -332,7 +332,7 @@ public:
|
||||||
int sys$futex(Userspace<const Syscall::SC_futex_params*>);
|
int sys$futex(Userspace<const Syscall::SC_futex_params*>);
|
||||||
int sys$set_thread_boost(pid_t tid, int amount);
|
int sys$set_thread_boost(pid_t tid, int amount);
|
||||||
int sys$set_process_boost(pid_t, int amount);
|
int sys$set_process_boost(pid_t, int amount);
|
||||||
int sys$chroot(const char* path, size_t path_length, int mount_flags);
|
int sys$chroot(Userspace<const char*> path, size_t path_length, int mount_flags);
|
||||||
int sys$pledge(Userspace<const Syscall::SC_pledge_params*>);
|
int sys$pledge(Userspace<const Syscall::SC_pledge_params*>);
|
||||||
int sys$unveil(Userspace<const Syscall::SC_unveil_params*>);
|
int sys$unveil(Userspace<const Syscall::SC_unveil_params*>);
|
||||||
int sys$perf_event(int type, FlatPtr arg1, FlatPtr arg2);
|
int sys$perf_event(int type, FlatPtr arg1, FlatPtr arg2);
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
|
|
||||||
namespace Kernel {
|
namespace Kernel {
|
||||||
|
|
||||||
int Process::sys$chroot(const char* user_path, size_t path_length, int mount_flags)
|
int Process::sys$chroot(Userspace<const char*> user_path, size_t path_length, int mount_flags)
|
||||||
{
|
{
|
||||||
if (!is_superuser())
|
if (!is_superuser())
|
||||||
return -EPERM;
|
return -EPERM;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue