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

Side by Side Diff: content/browser/zygote_host_linux.h

Issue 6995121: New NaCl zygote implementation 2 (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Fixing includes for Windows bots Created 9 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « content/browser/child_process_launcher.cc ('k') | content/browser/zygote_host_linux.cc » ('j') | 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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CONTENT_BROWSER_ZYGOTE_HOST_LINUX_H_ 5 #ifndef CONTENT_BROWSER_ZYGOTE_HOST_LINUX_H_
6 #define CONTENT_BROWSER_ZYGOTE_HOST_LINUX_H_ 6 #define CONTENT_BROWSER_ZYGOTE_HOST_LINUX_H_
7 #pragma once 7 #pragma once
8 8
9 #include <unistd.h> 9 #include <unistd.h>
10 10
11 #include <string> 11 #include <string>
(...skipping 13 matching lines...) Expand all
25 25
26 // The zygote host is the interface, in the browser process, to the zygote 26 // The zygote host is the interface, in the browser process, to the zygote
27 // process. 27 // process.
28 class ZygoteHost { 28 class ZygoteHost {
29 public: 29 public:
30 // Returns the singleton instance. 30 // Returns the singleton instance.
31 static ZygoteHost* GetInstance(); 31 static ZygoteHost* GetInstance();
32 32
33 void Init(const std::string& sandbox_cmd); 33 void Init(const std::string& sandbox_cmd);
34 34
35 // Tries to start a renderer process. Returns its pid on success, otherwise 35 // Tries to start a process of type indicated by process_type.
36 // Returns its pid on success, otherwise
36 // base::kNullProcessHandle; 37 // base::kNullProcessHandle;
37 pid_t ForkRenderer(const std::vector<std::string>& command_line, 38 pid_t ForkRequest(const std::vector<std::string>& command_line,
38 const base::GlobalDescriptors::Mapping& mapping); 39 const base::GlobalDescriptors::Mapping& mapping,
40 const std::string& process_type);
39 void EnsureProcessTerminated(pid_t process); 41 void EnsureProcessTerminated(pid_t process);
40 42
41 // Get the termination status (and, optionally, the exit code) of 43 // Get the termination status (and, optionally, the exit code) of
42 // the process. |exit_code| is set to the exit code of the child 44 // the process. |exit_code| is set to the exit code of the child
43 // process. (|exit_code| may be NULL.) 45 // process. (|exit_code| may be NULL.)
44 base::TerminationStatus GetTerminationStatus(base::ProcessHandle handle, 46 base::TerminationStatus GetTerminationStatus(base::ProcessHandle handle,
45 int* exit_code); 47 int* exit_code);
46 48
47 // These are the command codes used on the wire between the browser and the 49 // These are the command codes used on the wire between the browser and the
48 // zygote. 50 // zygote.
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 base::Lock control_lock_; 91 base::Lock control_lock_;
90 pid_t pid_; 92 pid_t pid_;
91 bool init_; 93 bool init_;
92 bool using_suid_sandbox_; 94 bool using_suid_sandbox_;
93 std::string sandbox_binary_; 95 std::string sandbox_binary_;
94 bool have_read_sandbox_status_word_; 96 bool have_read_sandbox_status_word_;
95 int sandbox_status_; 97 int sandbox_status_;
96 }; 98 };
97 99
98 #endif // CONTENT_BROWSER_ZYGOTE_HOST_LINUX_H_ 100 #endif // CONTENT_BROWSER_ZYGOTE_HOST_LINUX_H_
OLDNEW
« no previous file with comments | « content/browser/child_process_launcher.cc ('k') | content/browser/zygote_host_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698