OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chromeos/process_proxy/process_proxy.h" | 5 #include "chromeos/process_proxy/process_proxy.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdlib.h> | 8 #include <stdlib.h> |
9 #include <sys/ioctl.h> | 9 #include <sys/ioctl.h> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/command_line.h" | 12 #include "base/command_line.h" |
13 #include "base/files/file_util.h" | 13 #include "base/files/file_util.h" |
14 #include "base/location.h" | 14 #include "base/location.h" |
15 #include "base/logging.h" | 15 #include "base/logging.h" |
16 #include "base/posix/eintr_wrapper.h" | 16 #include "base/posix/eintr_wrapper.h" |
17 #include "base/process/launch.h" | 17 #include "base/process/launch.h" |
18 #include "base/process/process.h" | 18 #include "base/process/process.h" |
19 #include "base/single_thread_task_runner.h" | 19 #include "base/single_thread_task_runner.h" |
20 #include "base/thread_task_runner_handle.h" | 20 #include "base/threading/thread_task_runner_handle.h" |
21 #include "third_party/cros_system_api/switches/chrome_switches.h" | 21 #include "third_party/cros_system_api/switches/chrome_switches.h" |
22 | 22 |
23 namespace { | 23 namespace { |
24 | 24 |
25 enum PseudoTerminalFd { | 25 enum PseudoTerminalFd { |
26 PT_MASTER_FD, | 26 PT_MASTER_FD, |
27 PT_SLAVE_FD | 27 PT_SLAVE_FD |
28 }; | 28 }; |
29 | 29 |
30 const int kInvalidFd = -1; | 30 const int kInvalidFd = -1; |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
240 } | 240 } |
241 *fd = kInvalidFd; | 241 *fd = kInvalidFd; |
242 } | 242 } |
243 | 243 |
244 void ProcessProxy::ClearFdPair(int* pipe) { | 244 void ProcessProxy::ClearFdPair(int* pipe) { |
245 pipe[PT_MASTER_FD] = kInvalidFd; | 245 pipe[PT_MASTER_FD] = kInvalidFd; |
246 pipe[PT_SLAVE_FD] = kInvalidFd; | 246 pipe[PT_SLAVE_FD] = kInvalidFd; |
247 } | 247 } |
248 | 248 |
249 } // namespace chromeos | 249 } // namespace chromeos |
OLD | NEW |