| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/chromeos/drive/sync_client.h" | 5 #include "chrome/browser/chromeos/drive/sync_client.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/message_loop/message_loop_proxy.h" | 10 #include "base/message_loop/message_loop_proxy.h" |
| (...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 238 weak_ptr_factory_.GetWeakPtr(), | 238 weak_ptr_factory_.GetWeakPtr(), |
| 239 resource_id, | 239 resource_id, |
| 240 cache_entry)); | 240 cache_entry)); |
| 241 } | 241 } |
| 242 } | 242 } |
| 243 | 243 |
| 244 void SyncClient::OnGetResourceEntryById( | 244 void SyncClient::OnGetResourceEntryById( |
| 245 const std::string& resource_id, | 245 const std::string& resource_id, |
| 246 const FileCacheEntry& cache_entry, | 246 const FileCacheEntry& cache_entry, |
| 247 FileError error, | 247 FileError error, |
| 248 const base::FilePath& /* drive_file_path */, | |
| 249 scoped_ptr<ResourceEntry> entry) { | 248 scoped_ptr<ResourceEntry> entry) { |
| 250 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 249 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 251 | 250 |
| 252 if (entry.get() && !entry->has_file_specific_info()) | 251 if (entry.get() && !entry->has_file_specific_info()) |
| 253 error = FILE_ERROR_NOT_FOUND; | 252 error = FILE_ERROR_NOT_FOUND; |
| 254 | 253 |
| 255 if (error != FILE_ERROR_OK) { | 254 if (error != FILE_ERROR_OK) { |
| 256 LOG(WARNING) << "Entry not found: " << resource_id; | 255 LOG(WARNING) << "Entry not found: " << resource_id; |
| 257 return; | 256 return; |
| 258 } | 257 } |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 334 DVLOG(1) << "Uploaded " << resource_id; | 333 DVLOG(1) << "Uploaded " << resource_id; |
| 335 } else { | 334 } else { |
| 336 // TODO(satorux): We should re-queue if the error is recoverable. | 335 // TODO(satorux): We should re-queue if the error is recoverable. |
| 337 LOG(WARNING) << "Failed to upload " << resource_id << ": " | 336 LOG(WARNING) << "Failed to upload " << resource_id << ": " |
| 338 << FileErrorToString(error); | 337 << FileErrorToString(error); |
| 339 } | 338 } |
| 340 } | 339 } |
| 341 | 340 |
| 342 } // namespace internal | 341 } // namespace internal |
| 343 } // namespace drive | 342 } // namespace drive |
| OLD | NEW |