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

Side by Side Diff: components/nacl/zygote/nacl_fork_delegate_linux.cc

Issue 21031004: Move zygote related files to components/nacl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move nacl_fork_delegate_linux.h to components/nacl/zygote Created 7 years, 4 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 unified diff | Download patch
« no previous file with comments | « components/nacl/zygote/nacl_fork_delegate_linux.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "chrome/app/nacl_fork_delegate_linux.h" 5 #include "components/nacl/zygote/nacl_fork_delegate_linux.h"
6 6
7 #include <signal.h> 7 #include <signal.h>
8 #include <stdlib.h> 8 #include <stdlib.h>
9 #include <sys/resource.h> 9 #include <sys/resource.h>
10 #include <sys/socket.h> 10 #include <sys/socket.h>
11 11
12 #include <set> 12 #include <set>
13 13
14 #include "base/basictypes.h" 14 #include "base/basictypes.h"
15 #include "base/command_line.h" 15 #include "base/command_line.h"
16 #include "base/cpu.h" 16 #include "base/cpu.h"
17 #include "base/files/file_path.h" 17 #include "base/files/file_path.h"
18 #include "base/logging.h" 18 #include "base/logging.h"
19 #include "base/path_service.h" 19 #include "base/path_service.h"
20 #include "base/posix/eintr_wrapper.h" 20 #include "base/posix/eintr_wrapper.h"
21 #include "base/posix/unix_domain_socket_linux.h" 21 #include "base/posix/unix_domain_socket_linux.h"
22 #include "base/process/launch.h" 22 #include "base/process/launch.h"
23 #include "base/third_party/dynamic_annotations/dynamic_annotations.h" 23 #include "base/third_party/dynamic_annotations/dynamic_annotations.h"
24 #include "chrome/common/chrome_paths.h"
25 #include "components/nacl/common/nacl_helper_linux.h" 24 #include "components/nacl/common/nacl_helper_linux.h"
26 #include "components/nacl/common/nacl_paths.h" 25 #include "components/nacl/common/nacl_paths.h"
27 #include "components/nacl/common/nacl_switches.h" 26 #include "components/nacl/common/nacl_switches.h"
28 27
29 namespace { 28 namespace {
30 29
31 // Note these need to match up with their counterparts in nacl_helper_linux.c 30 // Note these need to match up with their counterparts in nacl_helper_linux.c
32 // and nacl_helper_bootstrap_linux.c. 31 // and nacl_helper_bootstrap_linux.c.
33 const char kNaClHelperReservedAtZero[] = 32 const char kNaClHelperReservedAtZero[] =
34 "--reserved_at_zero=0xXXXXXXXXXXXXXXXX"; 33 "--reserved_at_zero=0xXXXXXXXXXXXXXXXX";
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 214
216 bool NaClForkDelegate::AckChild(const int fd, 215 bool NaClForkDelegate::AckChild(const int fd,
217 const std::string& channel_switch) { 216 const std::string& channel_switch) {
218 int nwritten = HANDLE_EINTR(write(fd, channel_switch.c_str(), 217 int nwritten = HANDLE_EINTR(write(fd, channel_switch.c_str(),
219 channel_switch.length())); 218 channel_switch.length()));
220 if (nwritten != static_cast<int>(channel_switch.length())) { 219 if (nwritten != static_cast<int>(channel_switch.length())) {
221 return false; 220 return false;
222 } 221 }
223 return true; 222 return true;
224 } 223 }
OLDNEW
« no previous file with comments | « components/nacl/zygote/nacl_fork_delegate_linux.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698