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

Unified Diff: chrome/browser/shell_integration_linux.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
Index: chrome/browser/shell_integration_linux.cc
diff --git a/chrome/browser/shell_integration_linux.cc b/chrome/browser/shell_integration_linux.cc
index bdd609baeff8127390e1c84d8c2a28665de7fe2f..d19abc54362b07abc1c345257e3c013acc1785d0 100644
--- a/chrome/browser/shell_integration_linux.cc
+++ b/chrome/browser/shell_integration_linux.cc
@@ -103,9 +103,9 @@ std::string CreateShortcutIcon(const gfx::ImageFamily& icon_images,
<< width << ".";
continue;
}
- int bytes_written = file_util::WriteFile(temp_file_path,
- png_data->front_as<char>(),
- png_data->size());
+ int bytes_written = base::WriteFile(temp_file_path,
+ png_data->front_as<char>(),
+ png_data->size());
if (bytes_written != static_cast<int>(png_data->size()))
return std::string();
@@ -155,8 +155,8 @@ bool CreateShortcutOnDesktop(const base::FilePath& shortcut_filename,
return false;
}
- ssize_t bytes_written = file_util::WriteFileDescriptor(fd, contents.data(),
- contents.length());
+ ssize_t bytes_written = base::WriteFileDescriptor(fd, contents.data(),
+ contents.length());
if (IGNORE_EINTR(close(fd)) < 0)
PLOG(ERROR) << "close";
@@ -196,9 +196,9 @@ bool CreateShortcutInApplicationsMenu(const base::FilePath& shortcut_filename,
if (!directory_filename.empty()) {
temp_directory_path = temp_dir.path().Append(directory_filename);
- int bytes_written = file_util::WriteFile(temp_directory_path,
- directory_contents.data(),
- directory_contents.length());
+ int bytes_written = base::WriteFile(temp_directory_path,
+ directory_contents.data(),
+ directory_contents.length());
if (bytes_written != static_cast<int>(directory_contents.length()))
return false;
@@ -206,8 +206,8 @@ bool CreateShortcutInApplicationsMenu(const base::FilePath& shortcut_filename,
base::FilePath temp_file_path = temp_dir.path().Append(shortcut_filename);
- int bytes_written = file_util::WriteFile(temp_file_path, contents.data(),
- contents.length());
+ int bytes_written = base::WriteFile(temp_file_path, contents.data(),
+ contents.length());
if (bytes_written != static_cast<int>(contents.length()))
return false;

Powered by Google App Engine
This is Rietveld 408576698