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

Unified Diff: base/file_util.cc

Issue 14886003: Make base:ReplaceFile return an informative error. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ToT Created 7 years, 7 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
« no previous file with comments | « base/file_util.h ('k') | base/file_util_posix.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/file_util.cc
diff --git a/base/file_util.cc b/base/file_util.cc
index e76c5c2fd9afc1958c991382e55e727bd0552726..58dbd795d34f54b24b7e89251b94c81d1d8e5ba5 100644
--- a/base/file_util.cc
+++ b/base/file_util.cc
@@ -63,6 +63,11 @@ bool Move(const FilePath& from_path, const FilePath& to_path) {
return MoveUnsafe(from_path, to_path);
}
+bool ReplaceFile(const base::FilePath& from_path,
+ const base::FilePath& to_path) {
+ return ReplaceFileAndGetError(from_path, to_path, NULL);
+}
+
bool CopyFile(const FilePath& from_path, const FilePath& to_path) {
if (from_path.ReferencesParent() || to_path.ReferencesParent())
return false;
« no previous file with comments | « base/file_util.h ('k') | base/file_util_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698