diff options
author | bunnei <bunneidev@gmail.com> | 2021-05-11 00:53:07 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2021-05-11 05:33:53 +0200 |
commit | 44c763f9c6306a431739e69760ef3646141e2107 (patch) | |
tree | b6e0250305bcf1dbcc5a97e061785edbd98baaa5 /src | |
parent | hle: service: sm: Increase point buffer size. (diff) | |
download | yuzu-44c763f9c6306a431739e69760ef3646141e2107.tar yuzu-44c763f9c6306a431739e69760ef3646141e2107.tar.gz yuzu-44c763f9c6306a431739e69760ef3646141e2107.tar.bz2 yuzu-44c763f9c6306a431739e69760ef3646141e2107.tar.lz yuzu-44c763f9c6306a431739e69760ef3646141e2107.tar.xz yuzu-44c763f9c6306a431739e69760ef3646141e2107.tar.zst yuzu-44c763f9c6306a431739e69760ef3646141e2107.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/core/hle/service/sm/controller.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/core/hle/service/sm/controller.cpp b/src/core/hle/service/sm/controller.cpp index a8f5125ab..de530cbfb 100644 --- a/src/core/hle/service/sm/controller.cpp +++ b/src/core/hle/service/sm/controller.cpp @@ -26,15 +26,23 @@ void Controller::CloneCurrentObject(Kernel::HLERequestContext& ctx) { // TODO(bunnei): This is just creating a new handle to the same Session. I assume this is wrong // and that we probably want to actually make an entirely new Session, but we still need to // verify this on hardware. + LOG_DEBUG(Service, "called"); + auto session = ctx.Session()->GetParent(); + + // Open a reference to the session to simulate a new one being created. + session->Open(); + session->GetClientSession().Open(); + session->GetServerSession().Open(); + IPC::ResponseBuilder rb{ctx, 2, 0, 1, IPC::ResponseBuilder::Flags::AlwaysMoveHandles}; rb.Push(RESULT_SUCCESS); - rb.PushMoveObjects(ctx.Session()->GetParent()->GetClientSession()); + rb.PushMoveObjects(session->GetClientSession()); } void Controller::CloneCurrentObjectEx(Kernel::HLERequestContext& ctx) { - LOG_WARNING(Service, "(STUBBED) called, using CloneCurrentObject"); + LOG_DEBUG(Service, "called"); CloneCurrentObject(ctx); } |