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

Unified Diff: components/sync/engine_impl/directory_commit_contribution.cc

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 5 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: components/sync/engine_impl/directory_commit_contribution.cc
diff --git a/sync/engine/directory_commit_contribution.cc b/components/sync/engine_impl/directory_commit_contribution.cc
similarity index 90%
rename from sync/engine/directory_commit_contribution.cc
rename to components/sync/engine_impl/directory_commit_contribution.cc
index e52fa83217e423b2bde94fa7ed998cb2cef33a72..514bedbd1c839944cabe11ac82752ca438138911 100644
--- a/sync/engine/directory_commit_contribution.cc
+++ b/components/sync/engine_impl/directory_commit_contribution.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "sync/engine/directory_commit_contribution.h"
+#include "components/sync/engine_impl/directory_commit_contribution.h"
#include <stddef.h>
#include <stdint.h>
@@ -10,12 +10,12 @@
#include <algorithm>
#include <set>
-#include "sync/engine/commit_util.h"
-#include "sync/engine/get_commit_ids.h"
-#include "sync/engine/syncer_util.h"
-#include "sync/internal_api/public/sessions/commit_counters.h"
-#include "sync/syncable/model_neutral_mutable_entry.h"
-#include "sync/syncable/syncable_model_neutral_write_transaction.h"
+#include "components/sync/engine_impl/commit_util.h"
+#include "components/sync/engine_impl/get_commit_ids.h"
+#include "components/sync/engine_impl/syncer_util.h"
+#include "components/sync/sessions/commit_counters.h"
+#include "components/sync/syncable/model_neutral_mutable_entry.h"
+#include "components/sync/syncable/syncable_model_neutral_write_transaction.h"
namespace syncer {
@@ -64,8 +64,7 @@ void DirectoryCommitContribution::AddToCommitMessage(
DCHECK(syncing_bits_set_);
sync_pb::CommitMessage* commit_message = msg->mutable_commit();
entries_start_index_ = commit_message->entries_size();
- std::copy(entities_.begin(),
- entities_.end(),
+ std::copy(entities_.begin(), entities_.end(),
RepeatedPtrFieldBackInserter(commit_message->mutable_entries()));
if (!context_.context().empty())
commit_message->add_client_contexts()->Swap(&context_);
@@ -91,11 +90,8 @@ SyncerError DirectoryCommitContribution::ProcessCommitResponse(
for (size_t i = 0; i < metahandles_.size(); ++i) {
sync_pb::CommitResponse::ResponseType response_type =
commit_util::ProcessSingleCommitResponse(
- &trans,
- commit_response.entryresponse(entries_start_index_ + i),
- entities_.Get(i),
- metahandles_[i],
- &deleted_folders);
+ &trans, commit_response.entryresponse(entries_start_index_ + i),
+ entities_.Get(i), metahandles_[i], &deleted_folders);
switch (response_type) {
case sync_pb::CommitResponse::INVALID_MESSAGE:
++error_commits;
@@ -114,7 +110,7 @@ SyncerError DirectoryCommitContribution::ProcessCommitResponse(
status->increment_num_successful_commits();
break;
case sync_pb::CommitResponse::OVER_QUOTA:
- // We handle over quota like a retry, which is same as transient.
+ // We handle over quota like a retry, which is same as transient.
case sync_pb::CommitResponse::RETRY:
case sync_pb::CommitResponse::TRANSIENT_ERROR:
++transient_error_commits;

Powered by Google App Engine
This is Rietveld 408576698