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

Unified Diff: chrome/browser/password_manager/native_backend_kwallet_x.cc

Issue 920683002: [Password Generation] Add negative votes for crowdsourcing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Test fixes Created 5 years, 10 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
Index: chrome/browser/password_manager/native_backend_kwallet_x.cc
diff --git a/chrome/browser/password_manager/native_backend_kwallet_x.cc b/chrome/browser/password_manager/native_backend_kwallet_x.cc
index f31310b6c86025c764fe36cc583002362ec82218..e3e786146c07fa816c55713a9de31d397ca8d6cf 100644
--- a/chrome/browser/password_manager/native_backend_kwallet_x.cc
+++ b/chrome/browser/password_manager/native_backend_kwallet_x.cc
@@ -731,6 +731,7 @@ void NativeBackendKWallet::SerializeValue(
pickle->WriteString(form->avatar_url.spec());
pickle->WriteString(form->federation_url.spec());
pickle->WriteBool(form->skip_zero_click);
+ pickle->WriteInt(form->generation_upload_status);
}
}
@@ -783,6 +784,7 @@ bool NativeBackendKWallet::DeserializeValueSize(
int scheme = 0;
int64 date_created = 0;
int type = 0;
+ int generation_upload_status = 0;
// Note that these will be read back in the order listed due to
// short-circuit evaluation. This is important.
if (!iter.ReadInt(&scheme) ||
@@ -837,6 +839,15 @@ bool NativeBackendKWallet::DeserializeValueSize(
form->date_created = base::Time::FromTimeT(date_created);
}
+ if (version > 5) {
+ if (!iter.ReadInt(&generation_upload_status)) {
+ LogDeserializationWarning(version, signon_realm, false);
+ }
+ form->generation_upload_status =
+ static_cast<PasswordForm::GenerationUploadStatus>(
+ generation_upload_status);
+ }
+
forms->push_back(form.release());
}

Powered by Google App Engine
This is Rietveld 408576698