| Index: components/nacl/browser/nacl_process_host.h
|
| diff --git a/components/nacl/browser/nacl_process_host.h b/components/nacl/browser/nacl_process_host.h
|
| index eb138b61809f2f383ad2bc3c0d0c7efdb0a25cf1..94a23e1e0eeb01c2a8e9f72c3c72fec092a9093e 100644
|
| --- a/components/nacl/browser/nacl_process_host.h
|
| +++ b/components/nacl/browser/nacl_process_host.h
|
| @@ -7,6 +7,10 @@
|
|
|
| #include "build/build_config.h"
|
|
|
| +#include <string>
|
| +#include <utility>
|
| +#include <vector>
|
| +
|
| #include "base/files/file.h"
|
| #include "base/files/file_path.h"
|
| #include "base/files/file_util_proxy.h"
|
| @@ -46,6 +50,7 @@ void* AllocateAddressSpaceASLR(base::ProcessHandle process, size_t size);
|
| // running in the renderer and NaCl processes.
|
| class NaClProcessHost : public content::BrowserChildProcessHostDelegate {
|
| public:
|
| + class ResourceFileInfo;
|
| // manifest_url: the URL of the manifest of the Native Client plugin being
|
| // executed.
|
| // nexe_file: A file that corresponds to the nexe module to be loaded.
|
| @@ -57,16 +62,19 @@ class NaClProcessHost : public content::BrowserChildProcessHostDelegate {
|
| // off_the_record: was the process launched from an incognito renderer?
|
| // process_type: the type of NaCl process.
|
| // profile_directory: is the path of current profile directory.
|
| - NaClProcessHost(const GURL& manifest_url,
|
| - base::File nexe_file,
|
| - const NaClFileToken& nexe_token,
|
| - ppapi::PpapiPermissions permissions,
|
| - int render_view_id,
|
| - uint32 permission_bits,
|
| - bool uses_nonsfi_mode,
|
| - bool off_the_record,
|
| - NaClAppProcessType process_type,
|
| - const base::FilePath& profile_directory);
|
| + NaClProcessHost(
|
| + const GURL& manifest_url,
|
| + base::File nexe_file,
|
| + const NaClFileToken& nexe_token,
|
| + scoped_ptr<ResourceFileInfo[]> resource_files_info,
|
| + size_t resource_files_info_len_,
|
| + ppapi::PpapiPermissions permissions,
|
| + int render_view_id,
|
| + uint32 permission_bits,
|
| + bool uses_nonsfi_mode,
|
| + bool off_the_record,
|
| + NaClAppProcessType process_type,
|
| + const base::FilePath& profile_directory);
|
| ~NaClProcessHost() override;
|
|
|
| void OnProcessCrashed(int exit_status) override;
|
| @@ -95,6 +103,28 @@ class NaClProcessHost : public content::BrowserChildProcessHostDelegate {
|
| content::BrowserChildProcessHost* process() { return process_.get(); }
|
| content::BrowserPpapiHost* browser_ppapi_host() { return ppapi_host_.get(); }
|
|
|
| + class ResourceFileInfo {
|
| + MOVE_ONLY_TYPE_FOR_CPP_03(ResourceFileInfo, RValue);
|
| + public:
|
| + ResourceFileInfo();
|
| + ResourceFileInfo(base::File file,
|
| + const NaClFileToken& file_token,
|
| + const std::string& file_key);
|
| + ~ResourceFileInfo();
|
| +
|
| + ResourceFileInfo(RValue other);
|
| + ResourceFileInfo& operator=(RValue other);
|
| +
|
| + base::File file() { return file_.Pass(); }
|
| + const NaClFileToken& file_token() const { return file_token_; }
|
| + const std::string& file_key() const { return file_key_; }
|
| +
|
| + private:
|
| + base::File file_;
|
| + NaClFileToken file_token_;
|
| + std::string file_key_;
|
| + };
|
| +
|
| private:
|
| bool LaunchNaClGdb();
|
|
|
| @@ -182,6 +212,8 @@ class NaClProcessHost : public content::BrowserChildProcessHostDelegate {
|
| GURL manifest_url_;
|
| base::File nexe_file_;
|
| NaClFileToken nexe_token_;
|
| + scoped_ptr<ResourceFileInfo[]> resource_files_info_;
|
| + size_t resource_files_info_len_;
|
|
|
| ppapi::PpapiPermissions permissions_;
|
|
|
|
|