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

Side by Side Diff: components/nacl/browser/nacl_process_host.h

Issue 728113002: obsolete: SFI NaCl: Batch-open resource files (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 6 years, 1 month 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/browser/nacl_browser.cc ('k') | components/nacl/browser/nacl_process_host.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) 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 COMPONENTS_NACL_BROWSER_NACL_PROCESS_HOST_H_ 5 #ifndef COMPONENTS_NACL_BROWSER_NACL_PROCESS_HOST_H_
6 #define COMPONENTS_NACL_BROWSER_NACL_PROCESS_HOST_H_ 6 #define COMPONENTS_NACL_BROWSER_NACL_PROCESS_HOST_H_
7 7
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 9
10 #include <string> 10 #include <string>
11 #include <utility> 11 #include <utility>
12 #include <vector> 12 #include <vector>
13 13
14 #include "base/files/file.h" 14 #include "base/files/file.h"
15 #include "base/files/file_path.h" 15 #include "base/files/file_path.h"
16 #include "base/files/file_util_proxy.h" 16 #include "base/files/file_util_proxy.h"
17 #include "base/memory/ref_counted.h" 17 #include "base/memory/ref_counted.h"
18 #include "base/memory/shared_memory.h" 18 #include "base/memory/shared_memory.h"
19 #include "base/memory/weak_ptr.h" 19 #include "base/memory/weak_ptr.h"
20 #include "base/message_loop/message_loop.h" 20 #include "base/message_loop/message_loop.h"
21 #include "base/process/process.h" 21 #include "base/process/process.h"
22 #include "components/nacl/browser/nacl_browser.h"
22 #include "components/nacl/common/nacl_types.h" 23 #include "components/nacl/common/nacl_types.h"
23 #include "content/public/browser/browser_child_process_host_delegate.h" 24 #include "content/public/browser/browser_child_process_host_delegate.h"
24 #include "content/public/browser/browser_child_process_host_iterator.h" 25 #include "content/public/browser/browser_child_process_host_iterator.h"
25 #include "ipc/ipc_channel_handle.h" 26 #include "ipc/ipc_channel_handle.h"
26 #include "native_client/src/public/nacl_file_info.h" 27 #include "native_client/src/public/nacl_file_info.h"
27 #include "net/socket/socket_descriptor.h" 28 #include "net/socket/socket_descriptor.h"
28 #include "ppapi/shared_impl/ppapi_permissions.h" 29 #include "ppapi/shared_impl/ppapi_permissions.h"
29 #include "url/gurl.h" 30 #include "url/gurl.h"
30 31
31 namespace content { 32 namespace content {
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 168
168 // Sends the reply message to the renderer. Either result or 169 // Sends the reply message to the renderer. Either result or
169 // error message must be empty. 170 // error message must be empty.
170 void SendMessageToRenderer(const NaClLaunchResult& result, 171 void SendMessageToRenderer(const NaClLaunchResult& result,
171 const std::string& error_message); 172 const std::string& error_message);
172 173
173 // Sends the message to the NaCl process to load the plugin. Returns true 174 // Sends the message to the NaCl process to load the plugin. Returns true
174 // on success. 175 // on success.
175 bool StartNaClExecution(); 176 bool StartNaClExecution();
176 177
177 void StartNaClFileResolved( 178 void StartNaClFilesResolved(
178 NaClStartParams params, 179 NaClStartParams params,
179 const base::FilePath& file_path, 180 size_t checked_nexe_files_len,
180 base::File nexe_file); 181 scoped_ptr<OpenNaClFileReadExecImplResult[]> checked_nexe_files);
181 182
182 // Does post-process-launching tasks for starting the NaCl process once 183 // Does post-process-launching tasks for starting the NaCl process once
183 // we have a connection. 184 // we have a connection.
184 // 185 //
185 // Returns false on failure. 186 // Returns false on failure.
186 bool StartWithLaunchedProcess(); 187 bool StartWithLaunchedProcess();
187 188
188 // Message handlers for validation caching. 189 // Message handlers for validation caching.
189 void OnQueryKnownToValidate(const std::string& signature, bool* result); 190 void OnQueryKnownToValidate(const std::string& signature, bool* result);
190 void OnSetKnownToValidate(const std::string& signature); 191 void OnSetKnownToValidate(const std::string& signature);
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 base::File socket_for_sel_ldr_; 269 base::File socket_for_sel_ldr_;
269 270
270 base::WeakPtrFactory<NaClProcessHost> weak_factory_; 271 base::WeakPtrFactory<NaClProcessHost> weak_factory_;
271 272
272 DISALLOW_COPY_AND_ASSIGN(NaClProcessHost); 273 DISALLOW_COPY_AND_ASSIGN(NaClProcessHost);
273 }; 274 };
274 275
275 } // namespace nacl 276 } // namespace nacl
276 277
277 #endif // COMPONENTS_NACL_BROWSER_NACL_PROCESS_HOST_H_ 278 #endif // COMPONENTS_NACL_BROWSER_NACL_PROCESS_HOST_H_
OLDNEW
« no previous file with comments | « components/nacl/browser/nacl_browser.cc ('k') | components/nacl/browser/nacl_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698