Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(409)

Unified Diff: components/password_manager/core/browser/password_form_manager.cc

Issue 1416633010: Fix crash on a page navigation when Update Password bubble is active. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments fix Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/password_manager/core/browser/password_form_manager.cc
diff --git a/components/password_manager/core/browser/password_form_manager.cc b/components/password_manager/core/browser/password_form_manager.cc
index 1f135d55eeae28dc2532db6a3331dc1779c45522..562bf54a79241bc3c726f462d8c1d45d178981b6 100644
--- a/components/password_manager/core/browser/password_form_manager.cc
+++ b/components/password_manager/core/browser/password_form_manager.cc
@@ -879,10 +879,7 @@ bool PasswordFormManager::UploadChangePasswordForm(
DCHECK(password_type == autofill::NEW_PASSWORD ||
password_type == autofill::PROBABLY_NEW_PASSWORD ||
autofill::NOT_NEW_PASSWORD);
- // |new_password_element| might be empty in tests.
- // TODO: Fix it and add DCHECK. http://crbug.com/549525
- if (pending_credentials_.new_password_element.empty())
- return false;
+ DCHECK(!pending_credentials_.new_password_element.empty());
vasilii 2015/11/04 16:12:52 How is it related to the crash?
dvadym 2015/11/04 16:20:23 Since changes in this CL we can also fix todo from
vasilii 2015/11/04 16:24:36 We can. But in a separate CL only ;-)
dvadym 2015/11/04 16:44:15 Changes in manage_passwords_ui_controller.cc is al
autofill::AutofillManager* autofill_manager =
client_->GetAutofillManagerForMainFrame();
if (!autofill_manager || !autofill_manager->download_manager())

Powered by Google App Engine
This is Rietveld 408576698