| Index: content/browser/devtools/devtools_agent_host_impl.cc
|
| diff --git a/content/browser/devtools/devtools_agent_host_impl.cc b/content/browser/devtools/devtools_agent_host_impl.cc
|
| index cfe65e59cd2c4e577489f9f985714c9c7167cec3..4d935519c07e0fa2ee919e11ee9ec83bf5e751c8 100644
|
| --- a/content/browser/devtools/devtools_agent_host_impl.cc
|
| +++ b/content/browser/devtools/devtools_agent_host_impl.cc
|
| @@ -108,7 +108,7 @@ void DevToolsAgentHostImpl::AttachClient(DevToolsAgentHostClient* client) {
|
| scoped_refptr<DevToolsAgentHostImpl> protect(this);
|
| if (client_) {
|
| client_->AgentHostClosed(this, true);
|
| - Detach();
|
| + InnerDetach();
|
| }
|
| client_ = client;
|
| Attach();
|
| @@ -120,7 +120,12 @@ void DevToolsAgentHostImpl::DetachClient() {
|
|
|
| scoped_refptr<DevToolsAgentHostImpl> protect(this);
|
| client_ = NULL;
|
| + InnerDetach();
|
| +}
|
| +
|
| +void DevToolsAgentHostImpl::InnerDetach() {
|
| Detach();
|
| + io_context_.DiscardAllStreams();
|
| }
|
|
|
| bool DevToolsAgentHostImpl::IsAttached() {
|
| @@ -181,7 +186,7 @@ void DevToolsAgentHost::DetachAllClients() {
|
| DevToolsAgentHostClient* client = agent_host->client_;
|
| agent_host->client_ = NULL;
|
| client->AgentHostClosed(agent_host, true);
|
| - agent_host->Detach();
|
| + agent_host->InnerDetach();
|
| }
|
| }
|
| }
|
|
|