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

Side by Side Diff: content/zygote/zygote_linux.h

Issue 23123011: Zygote: small cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | content/zygote/zygote_linux.cc » ('j') | content/zygote/zygote_linux.cc » ('J')
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 #ifndef CONTENT_ZYGOTE_ZYGOTE_H_ 5 #ifndef CONTENT_ZYGOTE_ZYGOTE_H_
6 #define CONTENT_ZYGOTE_ZYGOTE_H_ 6 #define CONTENT_ZYGOTE_ZYGOTE_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 26 matching lines...) Expand all
37 struct ZygoteProcessInfo { 37 struct ZygoteProcessInfo {
38 // Pid from inside the Zygote's PID namespace. 38 // Pid from inside the Zygote's PID namespace.
39 base::ProcessHandle internal_pid; 39 base::ProcessHandle internal_pid;
40 // Keeps track of whether or not a process was started from a fork 40 // Keeps track of whether or not a process was started from a fork
41 // delegate helper. 41 // delegate helper.
42 bool started_from_helper; 42 bool started_from_helper;
43 }; 43 };
44 typedef base::SmallMap< std::map<base::ProcessHandle, ZygoteProcessInfo> > 44 typedef base::SmallMap< std::map<base::ProcessHandle, ZygoteProcessInfo> >
45 ZygoteProcessMap; 45 ZygoteProcessMap;
46 46
47 // Retrieve a ZygoteProcessInfo from the process_info_map_.
48 // Returns true and write to process_info if |pid| can be found, return
49 // false otherwise.
50 bool GetProcessInfo(base::ProcessHandle pid,
51 ZygoteProcessInfo* process_info);
52
47 // Returns true if the SUID sandbox is active. 53 // Returns true if the SUID sandbox is active.
48 bool UsingSUIDSandbox() const; 54 bool UsingSUIDSandbox() const;
49 55
50 // --------------------------------------------------------------------------- 56 // ---------------------------------------------------------------------------
51 // Requests from the browser... 57 // Requests from the browser...
52 58
53 // Read and process a request from the browser. Returns true if we are in a 59 // Read and process a request from the browser. Returns true if we are in a
54 // new process and thus need to unwind back into ChromeMain. 60 // new process and thus need to unwind back into ChromeMain.
55 bool HandleRequestFromBrowser(int fd); 61 bool HandleRequestFromBrowser(int fd);
56 62
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 // These might be set by helper_->InitialUMA. They supply a UMA enumeration 121 // These might be set by helper_->InitialUMA. They supply a UMA enumeration
116 // sample we should report on the first fork. 122 // sample we should report on the first fork.
117 std::string initial_uma_name_; 123 std::string initial_uma_name_;
118 int initial_uma_sample_; 124 int initial_uma_sample_;
119 int initial_uma_boundary_value_; 125 int initial_uma_boundary_value_;
120 }; 126 };
121 127
122 } // namespace content 128 } // namespace content
123 129
124 #endif // CONTENT_ZYGOTE_ZYGOTE_H_ 130 #endif // CONTENT_ZYGOTE_ZYGOTE_H_
OLDNEW
« no previous file with comments | « no previous file | content/zygote/zygote_linux.cc » ('j') | content/zygote/zygote_linux.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698