Kernel+UE+LibC: Store address as void* in SC_m{re,}map_params

Most other syscalls pass address arguments as `void*` instead of
`uintptr_t`, so let's do that here too. Besides improving consistency,
this commit makes `strace` correctly pretty-print these arguments in
hex.
This commit is contained in:
Daniel Bertalan 2021-12-22 13:20:32 +01:00 committed by Andreas Kling
commit 8e3d1a42e3
Notes: sideshowbarker 2024-07-18 00:54:03 +09:00
5 changed files with 8 additions and 8 deletions

View file

@ -123,7 +123,7 @@ ErrorOr<FlatPtr> Process::sys$mmap(Userspace<const Syscall::SC_mmap_params*> use
REQUIRE_PROMISE(stdio);
auto params = TRY(copy_typed_from_user(user_params));
FlatPtr addr = params.addr;
auto addr = (FlatPtr)params.addr;
auto size = params.size;
auto alignment = params.alignment ? params.alignment : PAGE_SIZE;
auto prot = params.prot;