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

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

Issue 224803002: Enable mmap and identity-based validation caching on pnacl-{llc,ld}.nexe (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix token handover for main nexe Created 6 years, 8 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 | « components/nacl/browser/nacl_browser.cc ('k') | components/nacl/browser/nacl_file_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_FILE_HOST_H_ 5 #ifndef COMPONENTS_NACL_BROWSER_NACL_FILE_HOST_H_
6 #define COMPONENTS_NACL_BROWSER_NACL_FILE_HOST_H_ 6 #define COMPONENTS_NACL_BROWSER_NACL_FILE_HOST_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 10 matching lines...) Expand all
21 21
22 namespace nacl { 22 namespace nacl {
23 class NaClHostMessageFilter; 23 class NaClHostMessageFilter;
24 } 24 }
25 25
26 // Opens NaCl Files in the Browser process, on behalf of the NaCl plugin. 26 // Opens NaCl Files in the Browser process, on behalf of the NaCl plugin.
27 27
28 namespace nacl_file_host { 28 namespace nacl_file_host {
29 29
30 // Open a PNaCl file (readonly) on behalf of the NaCl plugin. 30 // Open a PNaCl file (readonly) on behalf of the NaCl plugin.
31 // If it is executable, registers the executable for validation caching.
32 // Otherwise, just opens the file read-only.
31 void GetReadonlyPnaclFd( 33 void GetReadonlyPnaclFd(
32 scoped_refptr<nacl::NaClHostMessageFilter> nacl_host_message_filter, 34 scoped_refptr<nacl::NaClHostMessageFilter> nacl_host_message_filter,
33 const std::string& filename, 35 const std::string& filename,
36 bool is_executable,
34 IPC::Message* reply_msg); 37 IPC::Message* reply_msg);
35 38
36 // Return true if the filename requested is valid for opening. 39 // Return true if the filename requested is valid for opening.
37 // Sets file_to_open to the base::FilePath which we will attempt to open. 40 // Sets file_to_open to the base::FilePath which we will attempt to open.
38 bool PnaclCanOpenFile(const std::string& filename, 41 bool PnaclCanOpenFile(const std::string& filename,
39 base::FilePath* file_to_open); 42 base::FilePath* file_to_open);
40 43
41 // Opens a NaCl executable file for reading and executing. 44 // Opens a NaCl executable file for reading and executing.
42 void OpenNaClExecutable( 45 void OpenNaClExecutable(
43 scoped_refptr<nacl::NaClHostMessageFilter> nacl_host_message_filter, 46 scoped_refptr<nacl::NaClHostMessageFilter> nacl_host_message_filter,
44 int render_view_id, 47 int render_view_id,
45 const GURL& file_url, 48 const GURL& file_url,
46 IPC::Message* reply_msg); 49 IPC::Message* reply_msg);
47 50
48 } // namespace nacl_file_host 51 } // namespace nacl_file_host
49 52
50 #endif // COMPONENTS_NACL_BROWSER_NACL_FILE_HOST_H_ 53 #endif // COMPONENTS_NACL_BROWSER_NACL_FILE_HOST_H_
OLDNEW
« no previous file with comments | « components/nacl/browser/nacl_browser.cc ('k') | components/nacl/browser/nacl_file_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698