diff options
author | Andreas Kling <awesomekling@gmail.com> | 2019-05-30 12:38:35 +0200 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-05-30 12:38:35 +0200 |
commit | 66c1a9be3b01a508adec71910164f84e3bbe3923 (patch) | |
tree | cf78ad519588411cf9164f1854cca7d97e3dbada /Kernel/FileSystem | |
parent | 004a630bfef41e9cdc48878b86e7ae5958ff84dc (diff) | |
download | serenity-66c1a9be3b01a508adec71910164f84e3bbe3923.zip |
Kernel: Pass 'prot' argument to File::mmap() and act on it.
Nothing crazy, this just means that PROT_READ allocates readable regions,
and that PROT_WRITE allocates writable ones.
Diffstat (limited to 'Kernel/FileSystem')
-rw-r--r-- | Kernel/FileSystem/FileDescriptor.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/FileSystem/FileDescriptor.cpp b/Kernel/FileSystem/FileDescriptor.cpp index e199fdd298..24074afdc0 100644 --- a/Kernel/FileSystem/FileDescriptor.cpp +++ b/Kernel/FileSystem/FileDescriptor.cpp @@ -324,7 +324,7 @@ InodeMetadata FileDescriptor::metadata() const KResultOr<Region*> FileDescriptor::mmap(Process& process, LinearAddress laddr, size_t offset, size_t size, int prot) { if (m_file) - return m_file->mmap(process, laddr, offset, size); + return m_file->mmap(process, laddr, offset, size, prot); if (!is_fsfile()) return KResult(-ENODEV); |