diff options
author | Yuri Kunde Schlesner <yuriks@yuriks.net> | 2017-06-06 07:39:26 +0200 |
---|---|---|
committer | Yuri Kunde Schlesner <yuriks@yuriks.net> | 2017-06-06 11:56:32 +0200 |
commit | 6354d083594249fa1995be7b024943c258f63880 (patch) | |
tree | be459930c35e50f698ef7747730092116eea6a74 /src/core/hle/kernel/server_session.cpp | |
parent | ResultVal: Add more convenience utils for creating and cascading results (diff) | |
download | yuzu-6354d083594249fa1995be7b024943c258f63880.tar yuzu-6354d083594249fa1995be7b024943c258f63880.tar.gz yuzu-6354d083594249fa1995be7b024943c258f63880.tar.bz2 yuzu-6354d083594249fa1995be7b024943c258f63880.tar.lz yuzu-6354d083594249fa1995be7b024943c258f63880.tar.xz yuzu-6354d083594249fa1995be7b024943c258f63880.tar.zst yuzu-6354d083594249fa1995be7b024943c258f63880.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/kernel/server_session.cpp | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/src/core/hle/kernel/server_session.cpp b/src/core/hle/kernel/server_session.cpp index dc39d5229..2dc709bc9 100644 --- a/src/core/hle/kernel/server_session.cpp +++ b/src/core/hle/kernel/server_session.cpp @@ -28,16 +28,14 @@ ServerSession::~ServerSession() { parent->server = nullptr; } -ResultVal<SharedPtr<ServerSession>> ServerSession::Create( - std::string name, std::shared_ptr<SessionRequestHandler> hle_handler) { +ResultVal<SharedPtr<ServerSession>> ServerSession::Create(std::string name) { SharedPtr<ServerSession> server_session(new ServerSession); server_session->name = std::move(name); server_session->signaled = false; - server_session->hle_handler = std::move(hle_handler); server_session->parent = nullptr; - return MakeResult<SharedPtr<ServerSession>>(std::move(server_session)); + return MakeResult(std::move(server_session)); } bool ServerSession::ShouldWait(Thread* thread) const { @@ -71,13 +69,9 @@ ResultCode ServerSession::HandleSyncRequest() { return RESULT_SUCCESS; } -ServerSession::SessionPair ServerSession::CreateSessionPair( - const std::string& name, std::shared_ptr<SessionRequestHandler> hle_handler, - SharedPtr<ClientPort> port) { - - auto server_session = - ServerSession::Create(name + "_Server", std::move(hle_handler)).MoveFrom(); - +ServerSession::SessionPair ServerSession::CreateSessionPair(const std::string& name, + SharedPtr<ClientPort> port) { + auto server_session = ServerSession::Create(name + "_Server").MoveFrom(); SharedPtr<ClientSession> client_session(new ClientSession); client_session->name = name + "_Client"; |