| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/sync_file_system/drive_backend/local_to_remote_syncer.h
" | 5 #include "chrome/browser/sync_file_system/drive_backend/local_to_remote_syncer.h
" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 | 141 |
| 142 DCHECK(active_ancestor_details.file_kind() == FILE_KIND_FILE || | 142 DCHECK(active_ancestor_details.file_kind() == FILE_KIND_FILE || |
| 143 active_ancestor_details.file_kind() == FILE_KIND_FOLDER); | 143 active_ancestor_details.file_kind() == FILE_KIND_FOLDER); |
| 144 | 144 |
| 145 base::FilePath missing_entries; | 145 base::FilePath missing_entries; |
| 146 if (active_ancestor_path.empty()) { | 146 if (active_ancestor_path.empty()) { |
| 147 missing_entries = path; | 147 missing_entries = path; |
| 148 } else if (active_ancestor_path != path) { | 148 } else if (active_ancestor_path != path) { |
| 149 if (!active_ancestor_path.AppendRelativePath(path, &missing_entries)) { | 149 if (!active_ancestor_path.AppendRelativePath(path, &missing_entries)) { |
| 150 NOTREACHED(); | 150 NOTREACHED(); |
| 151 token->RecordLog(base::StringPrintf( | 151 token->RecordLog( |
| 152 "Detected invalid ancestor: %s", | 152 base::StringPrintf("Detected invalid ancestor: %" PRIsFP, |
| 153 active_ancestor_path.value().c_str())); | 153 active_ancestor_path.value().c_str())); |
| 154 SyncTaskManager::NotifyTaskDone(token.Pass(), SYNC_STATUS_FAILED); | 154 SyncTaskManager::NotifyTaskDone(token.Pass(), SYNC_STATUS_FAILED); |
| 155 return; | 155 return; |
| 156 } | 156 } |
| 157 } | 157 } |
| 158 | 158 |
| 159 std::vector<base::FilePath::StringType> missing_components; | 159 std::vector<base::FilePath::StringType> missing_components; |
| 160 storage::VirtualPath::GetComponents(missing_entries, &missing_components); | 160 storage::VirtualPath::GetComponents(missing_entries, &missing_components); |
| 161 | 161 |
| 162 if (!missing_components.empty()) { | 162 if (!missing_components.empty()) { |
| 163 if (local_is_missing_) { | 163 if (local_is_missing_) { |
| (...skipping 595 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 759 set_used_network(true); | 759 set_used_network(true); |
| 760 return sync_context_->GetDriveUploader(); | 760 return sync_context_->GetDriveUploader(); |
| 761 } | 761 } |
| 762 | 762 |
| 763 MetadataDatabase* LocalToRemoteSyncer::metadata_database() { | 763 MetadataDatabase* LocalToRemoteSyncer::metadata_database() { |
| 764 return sync_context_->GetMetadataDatabase(); | 764 return sync_context_->GetMetadataDatabase(); |
| 765 } | 765 } |
| 766 | 766 |
| 767 } // namespace drive_backend | 767 } // namespace drive_backend |
| 768 } // namespace sync_file_system | 768 } // namespace sync_file_system |
| OLD | NEW |