|
|
|
@ -234,11 +234,12 @@ static ResultCode ConnectToPort(Handle* out_handle, const char* port_name) {
|
|
|
|
|
auto client_session = std::get<Kernel::SharedPtr<Kernel::ClientSession>>(sessions);
|
|
|
|
|
auto server_session = std::get<Kernel::SharedPtr<Kernel::ServerSession>>(sessions);
|
|
|
|
|
|
|
|
|
|
// TODO(Subv): Wait the current thread until the ServerPort calls AcceptSession.
|
|
|
|
|
|
|
|
|
|
// Add the server session to the port's queue
|
|
|
|
|
client_port->AddWaitingSession(server_session);
|
|
|
|
|
|
|
|
|
|
// Note: Threads do not wait for the server endpoint to call
|
|
|
|
|
// AcceptSession before returning from this call.
|
|
|
|
|
|
|
|
|
|
// Return the client session
|
|
|
|
|
CASCADE_RESULT(*out_handle, Kernel::g_handle_table.Create(client_session));
|
|
|
|
|
return RESULT_SUCCESS;
|
|
|
|
|