aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/k_process.cpp
diff options
context:
space:
mode:
authorLiam <byteslice@airmail.cc>2023-03-07 12:01:07 -0500
committerLiam <byteslice@airmail.cc>2023-03-12 22:09:09 -0400
commitac6cbb7134d71134e4beae91361a78fa68202c22 (patch)
tree19ac300007ee99c87138203809005fb708257b21 /src/core/hle/kernel/k_process.cpp
parent641783df8f225bb455383747ee2d241c6458214a (diff)
kernel: prefer std::addressof
Diffstat (limited to 'src/core/hle/kernel/k_process.cpp')
-rw-r--r--src/core/hle/kernel/k_process.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/hle/kernel/k_process.cpp b/src/core/hle/kernel/k_process.cpp
index 4954a40db..b740fb1c3 100644
--- a/src/core/hle/kernel/k_process.cpp
+++ b/src/core/hle/kernel/k_process.cpp
@@ -44,12 +44,13 @@ void SetupMainThread(Core::System& system, KProcess& owner_process, u32 priority
SCOPE_EXIT({ thread->Close(); });
ASSERT(KThread::InitializeUserThread(system, thread, entry_point, 0, stack_top, priority,
- owner_process.GetIdealCoreId(), &owner_process)
+ owner_process.GetIdealCoreId(),
+ std::addressof(owner_process))
.IsSuccess());
// Register 1 must be a handle to the main thread
Handle thread_handle{};
- owner_process.GetHandleTable().Add(&thread_handle, thread);
+ owner_process.GetHandleTable().Add(std::addressof(thread_handle), thread);
thread->SetName("main");
thread->GetContext32().cpu_registers[0] = 0;
@@ -366,7 +367,7 @@ Result KProcess::LoadFromMetadata(const FileSys::ProgramMetadata& metadata, std:
// Initialize process address space
if (const Result result{page_table.InitializeForProcess(
metadata.GetAddressSpaceType(), false, false, false, KMemoryManager::Pool::Application,
- 0x8000000, code_size, &m_kernel.GetAppSystemResource(), resource_limit)};
+ 0x8000000, code_size, std::addressof(m_kernel.GetAppSystemResource()), resource_limit)};
result.IsError()) {
R_RETURN(result);
}