mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-04 14:02:45 +01:00
IPC: Don't create an unnecessary port when using PushIpcInterface outside of a domain.
This commit is contained in:
parent
de2e5a0855
commit
67c43e9200
1 changed files with 5 additions and 4 deletions
|
@ -118,10 +118,11 @@ public:
|
|||
if (context->IsDomain()) {
|
||||
context->AddDomainObject(std::move(iface));
|
||||
} else {
|
||||
auto port = iface->CreatePort();
|
||||
auto session = port->Connect();
|
||||
ASSERT(session.Succeeded());
|
||||
context->AddMoveObject(std::move(session).Unwrap());
|
||||
auto sessions = Kernel::ServerSession::CreateSessionPair(iface->GetServiceName());
|
||||
auto server = std::get<Kernel::SharedPtr<Kernel::ServerSession>>(sessions);
|
||||
auto client = std::get<Kernel::SharedPtr<Kernel::ClientSession>>(sessions);
|
||||
iface->ClientConnected(server);
|
||||
context->AddMoveObject(std::move(client));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue