| Index: components/nacl/common/nacl_types.h
|
| diff --git a/components/nacl/common/nacl_types.h b/components/nacl/common/nacl_types.h
|
| index e5b7136416162fd5f29564e1c8e3e5adc96454a3..6107dcaed3450035da7f031d7612bc3721f0d398 100644
|
| --- a/components/nacl/common/nacl_types.h
|
| +++ b/components/nacl/common/nacl_types.h
|
| @@ -58,14 +58,26 @@ enum NaClAppProcessType {
|
| kNumNaClProcessTypes
|
| };
|
|
|
| +// Represents a request to prefetch a file that's listed in the "files" section
|
| +// of a NaCl manifest file.
|
| +struct NaClResourcePrefetchRequest {
|
| + NaClResourcePrefetchRequest();
|
| + NaClResourcePrefetchRequest(const std::string& file_key,
|
| + const std::string& resource_url);
|
| + ~NaClResourcePrefetchRequest();
|
| +
|
| + std::string file_key; // a key for open_resource.
|
| + std::string resource_url;
|
| +};
|
| +
|
| // Represents a single prefetched file that's listed in the "files" section of
|
| // a NaCl manifest file.
|
| -struct NaClResourceFileInfo {
|
| - NaClResourceFileInfo();
|
| - NaClResourceFileInfo(IPC::PlatformFileForTransit file,
|
| - const base::FilePath& file_path,
|
| - const std::string& file_key);
|
| - ~NaClResourceFileInfo();
|
| +struct NaClResourcePrefetchResult {
|
| + NaClResourcePrefetchResult();
|
| + NaClResourcePrefetchResult(IPC::PlatformFileForTransit file,
|
| + const base::FilePath& file_path,
|
| + const std::string& file_key);
|
| + ~NaClResourcePrefetchResult();
|
|
|
| IPC::PlatformFileForTransit file;
|
| base::FilePath file_path_metadata; // a key for validation caching
|
| @@ -81,9 +93,15 @@ struct NaClStartParams {
|
| // Used only as a key for validation caching.
|
| base::FilePath nexe_file_path_metadata;
|
|
|
| - std::vector<NaClResourceFileInfo> prefetched_resource_files;
|
| - std::vector<FileDescriptor> handles;
|
| - FileDescriptor debug_stub_server_bound_socket;
|
| + std::vector<NaClResourcePrefetchResult> prefetched_resource_files;
|
| + IPC::PlatformFileForTransit imc_bootstrap_handle;
|
| + IPC::PlatformFileForTransit irt_handle;
|
| +#if defined(OS_MACOSX)
|
| + IPC::PlatformFileForTransit mac_shm_fd;
|
| +#endif
|
| +#if defined(OS_POSIX)
|
| + IPC::PlatformFileForTransit debug_stub_server_bound_socket;
|
| +#endif
|
|
|
| bool validation_cache_enabled;
|
| std::string validation_cache_key;
|
| @@ -116,9 +134,8 @@ struct NaClLaunchParams {
|
| const IPC::PlatformFileForTransit& nexe_file,
|
| uint64_t nexe_token_lo,
|
| uint64_t nexe_token_hi,
|
| - // A pair of a manifest key and its resource URL.
|
| const std::vector<
|
| - std::pair<std::string, std::string> >& resource_files_to_prefetch,
|
| + NaClResourcePrefetchRequest>& resource_prefetch_request_list,
|
| int render_view_id,
|
| uint32 permission_bits,
|
| bool uses_nonsfi_mode,
|
| @@ -132,7 +149,7 @@ struct NaClLaunchParams {
|
| IPC::PlatformFileForTransit nexe_file;
|
| uint64_t nexe_token_lo;
|
| uint64_t nexe_token_hi;
|
| - std::vector<std::pair<std::string, std::string> > resource_files_to_prefetch;
|
| + std::vector<NaClResourcePrefetchRequest> resource_prefetch_request_list;
|
|
|
| int render_view_id;
|
| uint32 permission_bits;
|
|
|