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

Unified Diff: chrome/browser/chromeos/drive/file_cache.cc

Issue 18332014: Move Copy* into the base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: windows Created 7 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: chrome/browser/chromeos/drive/file_cache.cc
diff --git a/chrome/browser/chromeos/drive/file_cache.cc b/chrome/browser/chromeos/drive/file_cache.cc
index a563da63a15bb26f8b34b27d148b04eb6218a4e5..47a44cb295fef05be04c052c99656b4343f821d5 100644
--- a/chrome/browser/chromeos/drive/file_cache.cc
+++ b/chrome/browser/chromeos/drive/file_cache.cc
@@ -90,10 +90,11 @@ bool MoveFile(const base::FilePath& source_path,
return true;
}
-// Copies the file.
-bool CopyFile(const base::FilePath& source_path,
- const base::FilePath& dest_path) {
- if (!file_util::CopyFile(source_path, dest_path)) {
+// Copies the file. Note this isn't called CopyFile which collides with
+// base::CopyFile when doing argument-dependent name lookup.
+bool CopyFileWrapper(const base::FilePath& source_path,
+ const base::FilePath& dest_path) {
+ if (!base::CopyFile(source_path, dest_path)) {
LOG(ERROR) << "Failed to copy " << source_path.value()
<< " to " << dest_path.value();
return false;
@@ -682,7 +683,7 @@ FileError FileCache::StoreInternal(const std::string& resource_id,
success = MoveFile(source_path, dest_path);
break;
case FILE_OPERATION_COPY:
- success = CopyFile(source_path, dest_path);
+ success = CopyFileWrapper(source_path, dest_path);
break;
default:
NOTREACHED();
« no previous file with comments | « chrome/browser/bookmarks/bookmark_storage.cc ('k') | chrome/browser/chromeos/drive/file_system/copy_operation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698