| Index: components/password_manager/content/renderer/credential_manager_client.cc
|
| diff --git a/components/password_manager/content/renderer/credential_manager_client.cc b/components/password_manager/content/renderer/credential_manager_client.cc
|
| index 1111e03a58dca3567e43b7e77d87c41a393d0597..aa3cbaa72ab60a9e0f4e2eff5820baf52797acdc 100644
|
| --- a/components/password_manager/content/renderer/credential_manager_client.cc
|
| +++ b/components/password_manager/content/renderer/credential_manager_client.cc
|
| @@ -266,6 +266,17 @@ void CredentialManagerClient::ConnectToMojoCMIfNeeded() {
|
|
|
| content::RenderFrame* main_frame = render_view()->GetMainRenderFrame();
|
| main_frame->GetRemoteInterfaces()->GetInterface(&mojo_cm_service_);
|
| +
|
| + // The remote end of the pipe will be forcibly closed by the browser side
|
| + // after each main frame navigation. Set up an error handler to reset the
|
| + // local end so that there will be an attempt at reestablishing the connection
|
| + // at the next call to the API.
|
| + mojo_cm_service_.set_connection_error_handler(base::Bind(
|
| + &CredentialManagerClient::OnMojoConnectionError, base::Unretained(this)));
|
| +}
|
| +
|
| +void CredentialManagerClient::OnMojoConnectionError() {
|
| + mojo_cm_service_.reset();
|
| }
|
|
|
| void CredentialManagerClient::OnDestruct() {
|
|
|