Index: chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc |
diff --git a/chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc b/chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc |
index 70353d3b3859c700df85426e8f6986c6fee852c4..f4523fc024c1c35443295156ae4300bef93d493b 100644 |
--- a/chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc |
+++ b/chrome/browser/extensions/api/messaging/native_process_launcher_posix.cc |
@@ -6,7 +6,6 @@ |
#include "base/command_line.h" |
#include "base/file_util.h" |
-#include "base/files/scoped_file.h" |
#include "base/logging.h" |
#include "base/path_service.h" |
#include "base/posix/eintr_wrapper.h" |
@@ -59,18 +58,18 @@ |
LOG(ERROR) << "Bad read pipe"; |
return false; |
} |
- base::ScopedFD read_pipe_read_fd(read_pipe_fds[0]); |
- base::ScopedFD read_pipe_write_fd(read_pipe_fds[1]); |
- fd_map.push_back(std::make_pair(read_pipe_write_fd.get(), STDOUT_FILENO)); |
+ file_util::ScopedFD read_pipe_read_fd(&read_pipe_fds[0]); |
+ file_util::ScopedFD read_pipe_write_fd(&read_pipe_fds[1]); |
+ fd_map.push_back(std::make_pair(*read_pipe_write_fd, STDOUT_FILENO)); |
int write_pipe_fds[2] = {0}; |
if (HANDLE_EINTR(pipe(write_pipe_fds)) != 0) { |
LOG(ERROR) << "Bad write pipe"; |
return false; |
} |
- base::ScopedFD write_pipe_read_fd(write_pipe_fds[0]); |
- base::ScopedFD write_pipe_write_fd(write_pipe_fds[1]); |
- fd_map.push_back(std::make_pair(write_pipe_read_fd.get(), STDIN_FILENO)); |
+ file_util::ScopedFD write_pipe_read_fd(&write_pipe_fds[0]); |
+ file_util::ScopedFD write_pipe_write_fd(&write_pipe_fds[1]); |
+ fd_map.push_back(std::make_pair(*write_pipe_read_fd, STDIN_FILENO)); |
base::LaunchOptions options; |
options.fds_to_remap = &fd_map; |
@@ -83,8 +82,8 @@ |
write_pipe_read_fd.reset(); |
read_pipe_write_fd.reset(); |
- *read_file = read_pipe_read_fd.release(); |
- *write_file = write_pipe_write_fd.release(); |
+ *read_file = *read_pipe_read_fd.release(); |
+ *write_file = *write_pipe_write_fd.release(); |
return true; |
} |