forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Verify consistency between sync and sign-in account IDs
Local sync metadata belongs to one user account. Due to the distributed nature of the locally persisted sync metadata, the cache GUID is used as "epoch" to detect mismatched in edge cases like the browser crashing during shutdown and before I/O gets flushed. However, prior to this patch, the cache GUID itself has no safety mechanism to detect it maps to the intended account ID. In this patch, a new SyncPref is introduced to achieve that, in away that both prefs (cache GUID and account ID) are stored atomically. Because the pref is newly-introduced, migration logic is introduced to populate it for the first time if initially empty. Change-Id: I2cdd9f997077c4acd16e9283df8c025f51d40546 Bug: 1046237,1021527 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2023528 Reviewed-by: Marc Treib <treib@chromium.org> Reviewed-by: Mihai Sardarescu <msarda@chromium.org> Commit-Queue: Mikel Astiz <mastiz@chromium.org> Cr-Commit-Position: refs/heads/master@{#736848}
- Loading branch information
Mikel Astiz
authored and
Commit Bot
committed
Jan 30, 2020
1 parent
f9edfaf
commit caf8eeb
Showing
6 changed files
with
131 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters