summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/hle_ipc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/kernel/hle_ipc.cpp')
-rw-r--r--src/core/hle/kernel/hle_ipc.cpp20
1 files changed, 4 insertions, 16 deletions
diff --git a/src/core/hle/kernel/hle_ipc.cpp b/src/core/hle/kernel/hle_ipc.cpp
index 24700f7a5..689f58cf6 100644
--- a/src/core/hle/kernel/hle_ipc.cpp
+++ b/src/core/hle/kernel/hle_ipc.cpp
@@ -35,11 +35,11 @@ SessionRequestHandler::SessionRequestHandler() = default;
SessionRequestHandler::~SessionRequestHandler() = default;
void SessionRequestHandler::ClientConnected(KServerSession* session) {
- session->SetHleHandler(shared_from_this());
+ session->SetSessionHandler(shared_from_this());
}
void SessionRequestHandler::ClientDisconnected(KServerSession* session) {
- session->SetHleHandler(nullptr);
+ session->SetSessionHandler(nullptr);
}
HLERequestContext::HLERequestContext(KernelCore& kernel_, Core::Memory::Memory& memory_,
@@ -186,18 +186,6 @@ ResultCode HLERequestContext::WriteToOutgoingCommandBuffer(KThread& requesting_t
auto& owner_process = *requesting_thread.GetOwnerProcess();
auto& handle_table = owner_process.GetHandleTable();
- // The data_size already includes the payload header, the padding and the domain header.
- std::size_t size{};
-
- if (IsTipc()) {
- size = cmd_buf.size();
- } else {
- size = data_payload_offset + data_size - sizeof(IPC::DataPayloadHeader) / sizeof(u32) - 4;
- if (Session()->IsDomain()) {
- size -= sizeof(IPC::DomainMessageHeader) / sizeof(u32);
- }
- }
-
for (auto& object : copy_objects) {
Handle handle{};
if (object) {
@@ -222,7 +210,7 @@ ResultCode HLERequestContext::WriteToOutgoingCommandBuffer(KThread& requesting_t
if (Session()->IsDomain()) {
current_offset = domain_offset - static_cast<u32>(domain_objects.size());
for (const auto& object : domain_objects) {
- server_session->AppendDomainRequestHandler(object);
+ server_session->AppendDomainHandler(object);
cmd_buf[current_offset++] =
static_cast<u32_le>(server_session->NumDomainRequestHandlers());
}
@@ -230,7 +218,7 @@ ResultCode HLERequestContext::WriteToOutgoingCommandBuffer(KThread& requesting_t
// Copy the translated command buffer back into the thread's command buffer area.
memory.WriteBlock(owner_process, requesting_thread.GetTLSAddress(), cmd_buf.data(),
- size * sizeof(u32));
+ write_size * sizeof(u32));
return RESULT_SUCCESS;
}