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

Unified Diff: chrome/test/chromedriver/chrome_launcher.cc

Issue 184563006: Move WriteFile and WriteFileDescriptor from file_util to base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 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 | « chrome/test/chromedriver/chrome/zip_reader.cc ('k') | chrome/test/chromedriver/util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/chromedriver/chrome_launcher.cc
diff --git a/chrome/test/chromedriver/chrome_launcher.cc b/chrome/test/chromedriver/chrome_launcher.cc
index e006ff56bfa70d919ff924f8899e35f139de2bcc..44a4ad822e63668607be6aa9ebbafe204a1ab11f 100644
--- a/chrome/test/chromedriver/chrome_launcher.cc
+++ b/chrome/test/chromedriver/chrome_launcher.cc
@@ -65,7 +65,7 @@ Status UnpackAutomationExtension(const base::FilePath& temp_dir,
base::FilePath extension_zip = temp_dir.AppendASCII("internal.zip");
int size = static_cast<int>(decoded_extension.length());
- if (file_util::WriteFile(extension_zip, decoded_extension.c_str(), size)
+ if (base::WriteFile(extension_zip, decoded_extension.c_str(), size)
!= size) {
return Status(kUnknownError, "failed to write automation extension zip");
}
@@ -513,7 +513,7 @@ Status ProcessExtension(const std::string& extension,
return Status(kUnknownError, "cannot create temp dir");
base::FilePath extension_crx = temp_crx_dir.path().AppendASCII("temp.crx");
int size = static_cast<int>(decoded_extension.length());
- if (file_util::WriteFile(extension_crx, decoded_extension.c_str(), size) !=
+ if (base::WriteFile(extension_crx, decoded_extension.c_str(), size) !=
size) {
return Status(kUnknownError, "cannot write file");
}
@@ -553,7 +553,7 @@ Status ProcessExtension(const std::string& extension,
} else {
manifest->SetString("key", public_key_base64);
base::JSONWriter::Write(manifest, &manifest_data);
- if (file_util::WriteFile(
+ if (base::WriteFile(
manifest_path, manifest_data.c_str(), manifest_data.size()) !=
static_cast<int>(manifest_data.size())) {
return Status(kUnknownError, "cannot add 'key' to manifest");
@@ -651,7 +651,7 @@ Status WritePrefsFile(
base::JSONWriter::Write(prefs, &prefs_str);
VLOG(0) << "Populating " << path.BaseName().value()
<< " file: " << PrettyPrintValue(*prefs);
- if (static_cast<int>(prefs_str.length()) != file_util::WriteFile(
+ if (static_cast<int>(prefs_str.length()) != base::WriteFile(
path, prefs_str.c_str(), prefs_str.length())) {
return Status(kUnknownError, "failed to write prefs file");
}
@@ -682,7 +682,7 @@ Status PrepareUserDataDir(
// Write empty "First Run" file, otherwise Chrome will wipe the default
// profile that was written.
- if (file_util::WriteFile(
+ if (base::WriteFile(
user_data_dir.Append(chrome::kFirstRunSentinel), "", 0) != 0) {
return Status(kUnknownError, "failed to write first run file");
}
« no previous file with comments | « chrome/test/chromedriver/chrome/zip_reader.cc ('k') | chrome/test/chromedriver/util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698