diff options
author | Andreas Kling <kling@serenityos.org> | 2022-08-21 16:02:24 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-08-21 16:02:24 +0200 |
commit | c3351d4b9fc83c731f122de21adf52ef015aecb1 (patch) | |
tree | 003ab8dd231db1469f807d5c9cdd2bb33303ac50 /Kernel/Syscalls/chmod.cpp | |
parent | 9744dedb5008ee4c20e01166b46bc56fcbdcbd12 (diff) | |
download | serenity-c3351d4b9fc83c731f122de21adf52ef015aecb1.zip |
Kernel: Make VirtualFileSystem functions take credentials as input
Instead of getting credentials from Process::current(), we now require
that they be provided as input to the various VFS functions.
This ensures that an atomic set of credentials is used throughout an
entire VFS operation.
Diffstat (limited to 'Kernel/Syscalls/chmod.cpp')
-rw-r--r-- | Kernel/Syscalls/chmod.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Syscalls/chmod.cpp b/Kernel/Syscalls/chmod.cpp index c1f2e2fc8d..0b5db76bd3 100644 --- a/Kernel/Syscalls/chmod.cpp +++ b/Kernel/Syscalls/chmod.cpp @@ -28,7 +28,7 @@ ErrorOr<FlatPtr> Process::sys$chmod(Userspace<Syscall::SC_chmod_params const*> u base = base_description->custody(); } - TRY(VirtualFileSystem::the().chmod(path->view(), params.mode, *base, params.follow_symlinks ? 0 : O_NOFOLLOW_NOERROR)); + TRY(VirtualFileSystem::the().chmod(credentials(), path->view(), params.mode, *base, params.follow_symlinks ? 0 : O_NOFOLLOW_NOERROR)); return 0; } |