diff options
author | zea@chromium.org <zea@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-07 23:23:04 +0000 |
---|---|---|
committer | zea@chromium.org <zea@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-07 23:23:04 +0000 |
commit | 5bc0345a9a4fd58f4da16f2aa0175a8a1edbda51 (patch) | |
tree | e82f55bbb26dac220d66ca97cf01eb88bb7add3c /chrome | |
parent | cac10fc621aec369c6491a9db28c3bccce9220ea (diff) | |
download | chromium_src-5bc0345a9a4fd58f4da16f2aa0175a8a1edbda51.zip chromium_src-5bc0345a9a4fd58f4da16f2aa0175a8a1edbda51.tar.gz chromium_src-5bc0345a9a4fd58f4da16f2aa0175a8a1edbda51.tar.bz2 |
[Sync] Don't early out of ReEncryptEverything when a datatype is missing.
This happens upon restart when we upgrade and have a new type. We won't have
the root for that type at the time we refresh encryption, so just skip it for
now.
BUG=99219
TEST=Set up sync with encryption everything on a new client. Restart with
--enable-sync-tabs on and ensure we don't hit a NOTREACHED.
Review URL: http://codereview.chromium.org/8159005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@104601 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/sync/internal_api/sync_manager.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/chrome/browser/sync/internal_api/sync_manager.cc b/chrome/browser/sync/internal_api/sync_manager.cc index d617129..97fa9ae 100644 --- a/chrome/browser/sync/internal_api/sync_manager.cc +++ b/chrome/browser/sync/internal_api/sync_manager.cc @@ -1149,8 +1149,11 @@ void SyncManager::SyncInternal::ReEncryptEverything(WriteTransaction* trans) { ReadNode type_root(trans); tag = syncable::ModelTypeToRootTag(*iter); if (!type_root.InitByTagLookup(tag)) { - NOTREACHED(); - return; + // This can happen when we enable a datatype for the first time on restart + // (for example when we upgrade) and therefore haven't done the initial + // download for that type at the time we RefreshEncryption. There's + // nothing we can do for now, so just move on to the next type. + continue; } // Iterate through all children of this datatype. |