mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 04:48:14 +00:00
LibIPC+Services: Make ClientConnection take socket as NonnullRefPtr
This avoids getting into the awkward situation where the socket is still part-owned by main() in multi-instance service. Also it just reads nicer.
This commit is contained in:
parent
f9d3055691
commit
94ddb07e58
25 changed files with 40 additions and 40 deletions
|
@ -36,8 +36,8 @@ namespace ImageDecoder {
|
|||
|
||||
static HashMap<int, RefPtr<ClientConnection>> s_connections;
|
||||
|
||||
ClientConnection::ClientConnection(Core::LocalSocket& socket, int client_id)
|
||||
: IPC::ClientConnection<ImageDecoderServerEndpoint>(*this, socket, client_id)
|
||||
ClientConnection::ClientConnection(NonnullRefPtr<Core::LocalSocket> socket, int client_id)
|
||||
: IPC::ClientConnection<ImageDecoderServerEndpoint>(*this, move(socket), client_id)
|
||||
{
|
||||
s_connections.set(client_id, *this);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue