Index: components/autofill/content/renderer/password_autofill_agent.cc |
diff --git a/components/autofill/content/renderer/password_autofill_agent.cc b/components/autofill/content/renderer/password_autofill_agent.cc |
index faef1b513fc0723460868f1df721ca2354cb62d6..8b18ee962940f9bb53417d6d17151097d113732a 100644 |
--- a/components/autofill/content/renderer/password_autofill_agent.cc |
+++ b/components/autofill/content/renderer/password_autofill_agent.cc |
@@ -1236,6 +1236,10 @@ void PasswordAutofillAgent::WillSubmitForm(const blink::WebFormElement& form) { |
} |
} |
+void PasswordAutofillAgent::OnDestruct() { |
+ base::ThreadTaskRunnerHandle::Get()->DeleteSoon(FROM_HERE, this); |
+} |
+ |
void PasswordAutofillAgent::DidStartProvisionalLoad() { |
std::unique_ptr<RendererSavePasswordProgressLogger> logger; |
if (logging_state_active_) { |