mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-07 09:04:30 +00:00
Kernel: Allow mmap() with a size that's not a multiple of page size.
We just round it up to the next multiple of page size anyway.
This commit is contained in:
@@ -162,7 +162,7 @@ void* Process::sys$mmap(const Syscall::SC_mmap_params* params)
|
||||
off_t offset = params->offset;
|
||||
if (size == 0)
|
||||
return (void*)-EINVAL;
|
||||
if ((dword)addr & ~PAGE_MASK || size & ~PAGE_MASK)
|
||||
if ((dword)addr & ~PAGE_MASK)
|
||||
return (void*)-EINVAL;
|
||||
if (flags & MAP_ANONYMOUS) {
|
||||
// FIXME: Implement mapping at a client-specified address. Most of the support is already in plcae.
|
||||
|
||||
Reference in New Issue
Block a user