mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:38:11 +00:00
WebDriver: Fix handling of disconnected WebContent process
If WebContent process got disconnected it is only necessary to remove associated window instead of terminating the entire session.
This commit is contained in:
parent
7146c33522
commit
16a4949e33
3 changed files with 13 additions and 11 deletions
|
@ -9,17 +9,15 @@
|
|||
|
||||
namespace WebDriver {
|
||||
|
||||
WebContentConnection::WebContentConnection(NonnullOwnPtr<Core::LocalSocket> socket, NonnullRefPtr<Client> client, unsigned session_id)
|
||||
WebContentConnection::WebContentConnection(NonnullOwnPtr<Core::LocalSocket> socket)
|
||||
: IPC::ConnectionFromClient<WebDriverClientEndpoint, WebDriverServerEndpoint>(*this, move(socket), 1)
|
||||
, m_client(move(client))
|
||||
, m_session_id(session_id)
|
||||
{
|
||||
}
|
||||
|
||||
void WebContentConnection::die()
|
||||
{
|
||||
dbgln_if(WEBDRIVER_DEBUG, "Session {} was closed remotely. Shutting down...", m_session_id);
|
||||
m_client->close_session(m_session_id);
|
||||
if (on_close)
|
||||
on_close();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue