DescriptionSync: fix for the code that checks whether the initial download has completed
The code that detects whether the initial download has completed for
a type had been inadvertently broken by https://codereview.chromium.org/1142423006/
This fix changes Directory::InitialSyncEndedForType back to the
original implementation and adds special handling for implicitly created
root folders (i.e. root folders auto-created locally by the update
handling code). Since the locally created root folders don't get applied
with the rest of downloaded nodes, their base version has to be
explicitly changed from CHANGES_VERSION to some other value at
the end of update application process. That would to indicate that at
least one update has been applied for the type and be consistent with
how the server generated root folders are handled.
BUG=540814
Committed: https://crrev.com/b691b7a0f29e7ebafad5fadb8a6d59cce8cff279
Cr-Commit-Position: refs/heads/master@{#353913}
Patch Set 1 #Patch Set 2 : Fixed control data types and added unit tests #
Total comments: 4
Patch Set 3 : Added more tests #
Total comments: 6
Patch Set 4 : Addressed CR feedback #
Messages
Total messages: 15 (4 generated)
|