mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-07 08:39:22 +00:00
Everywhere: Make TransportSocket non-movable
Instead of wrapping all non-movable members of TransportSocket in OwnPtr to keep it movable, make TransportSocket itself non-movable and wrap it in OwnPtr.
This commit is contained in:
parent
79c22e0d86
commit
db8c443392
Notes:
github-actions[bot]
2025-04-09 13:28:53 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: db8c443392
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4287
42 changed files with 97 additions and 100 deletions
|
@ -264,7 +264,7 @@ int ConnectionFromClient::on_timeout_callback(void*, long timeout_ms, void* user
|
|||
return 0;
|
||||
}
|
||||
|
||||
ConnectionFromClient::ConnectionFromClient(IPC::Transport transport)
|
||||
ConnectionFromClient::ConnectionFromClient(NonnullOwnPtr<IPC::Transport> transport)
|
||||
: IPC::ConnectionFromClient<RequestClientEndpoint, RequestServerEndpoint>(*this, move(transport), s_client_ids.allocate())
|
||||
, m_resolver(default_resolver())
|
||||
{
|
||||
|
@ -335,7 +335,7 @@ Messages::RequestServer::ConnectNewClientResponse ConnectionFromClient::connect_
|
|||
}
|
||||
auto client_socket = client_socket_or_error.release_value();
|
||||
// Note: A ref is stored in the static s_connections map
|
||||
auto client = adopt_ref(*new ConnectionFromClient(IPC::Transport(move(client_socket))));
|
||||
auto client = adopt_ref(*new ConnectionFromClient(make<IPC::Transport>(move(client_socket))));
|
||||
|
||||
return IPC::File::adopt_fd(socket_fds[1]);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue