| Index: chrome/browser/sync/engine/syncer.cc
|
| ===================================================================
|
| --- chrome/browser/sync/engine/syncer.cc (revision 94934)
|
| +++ chrome/browser/sync/engine/syncer.cc (working copy)
|
| @@ -72,12 +72,14 @@
|
| }
|
|
|
| void Syncer::SyncShare(sessions::SyncSession* session,
|
| - const SyncerStep first_step,
|
| - const SyncerStep last_step) {
|
| - ScopedDirLookup dir(session->context()->directory_manager(),
|
| - session->context()->account_name());
|
| - // The directory must be good here.
|
| - CHECK(dir.good());
|
| + SyncerStep first_step,
|
| + SyncerStep last_step) {
|
| + {
|
| + ScopedDirLookup dir(session->context()->directory_manager(),
|
| + session->context()->account_name());
|
| + // The directory must be good here.
|
| + CHECK(dir.good());
|
| + }
|
|
|
| ScopedSessionContextConflictResolver scoped(session->context(),
|
| &resolver_);
|
| @@ -153,7 +155,14 @@
|
| VLOG(1) << "Applying Updates";
|
| ApplyUpdatesCommand apply_updates;
|
| apply_updates.Execute(session);
|
| - next_step = BUILD_COMMIT_REQUEST;
|
| + if (last_step == APPLY_UPDATES) {
|
| + // We're in configuration mode, but we still need to run the
|
| + // SYNCER_END step.
|
| + last_step = SYNCER_END;
|
| + next_step = SYNCER_END;
|
| + } else {
|
| + next_step = BUILD_COMMIT_REQUEST;
|
| + }
|
| break;
|
| }
|
| // These two steps are combined since they are executed within the same
|
| @@ -264,6 +273,10 @@
|
| break;
|
| }
|
| case SYNCER_END: {
|
| + VLOG(1) << "Syncer End";
|
| + SyncerEndCommand syncer_end_command;
|
| + syncer_end_command.Execute(session);
|
| + next_step = SYNCER_END;
|
| break;
|
| }
|
| default:
|
| @@ -277,15 +290,6 @@
|
| break;
|
| current_step = next_step;
|
| }
|
| -
|
| - VLOG(1) << "Syncer End";
|
| - VLOG(2) << "last step: " << last_step << ", current step: "
|
| - << current_step << ", next step: "
|
| - << next_step << ", snapshot: "
|
| - << session->TakeSnapshot().ToString();
|
| - SyncerEndCommand syncer_end_command;
|
| - syncer_end_command.Execute(session);
|
| - return;
|
| }
|
|
|
| void Syncer::ProcessClientCommand(sessions::SyncSession* session) {
|
|
|