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

Unified Diff: chrome/utility/importer/external_process_importer_bridge.cc

Issue 665113002: Collect statistics from the importer on empty usernames and passwords from other browsers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months 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
« no previous file with comments | « chrome/browser/importer/in_process_importer_bridge.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/utility/importer/external_process_importer_bridge.cc
diff --git a/chrome/utility/importer/external_process_importer_bridge.cc b/chrome/utility/importer/external_process_importer_bridge.cc
index 56c82be6be74ae495eaf62bf382dbb9fd5944d2d..fcfc61f20b1a4331d8a5ae2f4cf7a6f707e65164 100644
--- a/chrome/utility/importer/external_process_importer_bridge.cc
+++ b/chrome/utility/importer/external_process_importer_bridge.cc
@@ -5,6 +5,7 @@
#include "chrome/utility/importer/external_process_importer_bridge.h"
#include "base/bind.h"
+#include "base/debug/dump_without_crashing.h"
#include "base/logging.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/utf_string_conversions.h"
@@ -26,7 +27,16 @@ const int kNumBookmarksToSend = 100;
const int kNumHistoryRowsToSend = 100;
const int kNumFaviconsToSend = 100;
const int kNumAutofillFormDataToSend = 100;
+
+// http://crbug.com/404012. Let's see where the empty fields come from.
+void CheckForEmptyUsernameAndPassword(const autofill::PasswordForm& form) {
+ if (form.username_value.empty() &&
+ form.password_value.empty() &&
+ !form.blacklisted_by_user) {
+ base::debug::DumpWithoutCrashing();
+ }
}
+} // namespace
ExternalProcessImporterBridge::ExternalProcessImporterBridge(
const base::DictionaryValue& localized_strings,
@@ -138,6 +148,7 @@ void ExternalProcessImporterBridge::SetFirefoxSearchEnginesXMLData(
void ExternalProcessImporterBridge::SetPasswordForm(
const autofill::PasswordForm& form) {
+ CheckForEmptyUsernameAndPassword(form);
Send(new ProfileImportProcessHostMsg_NotifyPasswordFormReady(form));
}
« no previous file with comments | « chrome/browser/importer/in_process_importer_bridge.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698