OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "components/nacl/renderer/ppb_nacl_private_impl.h" | 5 #include "components/nacl/renderer/ppb_nacl_private_impl.h" |
6 | 6 |
7 #include <numeric> | 7 #include <numeric> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 perm_bits |= ppapi::PERMISSION_DEV; | 415 perm_bits |= ppapi::PERMISSION_DEV; |
416 instance_info.permissions = | 416 instance_info.permissions = |
417 ppapi::PpapiPermissions::GetForCommandLine(perm_bits); | 417 ppapi::PpapiPermissions::GetForCommandLine(perm_bits); |
418 std::string error_message_string; | 418 std::string error_message_string; |
419 NaClLaunchResult launch_result; | 419 NaClLaunchResult launch_result; |
420 | 420 |
421 IPC::PlatformFileForTransit nexe_for_transit = | 421 IPC::PlatformFileForTransit nexe_for_transit = |
422 IPC::InvalidPlatformFileForTransit(); | 422 IPC::InvalidPlatformFileForTransit(); |
423 | 423 |
424 std::vector<NaClResourcePrefetchRequest> resource_prefetch_request_list; | 424 std::vector<NaClResourcePrefetchRequest> resource_prefetch_request_list; |
425 if (process_type == kNativeNaClProcessType && uses_nonsfi_mode) { | 425 if (process_type == kNativeNaClProcessType) { |
426 JsonManifest* manifest = GetJsonManifest(instance); | 426 JsonManifest* manifest = GetJsonManifest(instance); |
427 if (manifest) { | 427 if (manifest) { |
428 manifest->GetPrefetchableFiles(&resource_prefetch_request_list); | 428 manifest->GetPrefetchableFiles(&resource_prefetch_request_list); |
429 | 429 |
430 for (size_t i = 0; i < resource_prefetch_request_list.size(); ++i) { | 430 for (size_t i = 0; i < resource_prefetch_request_list.size(); ++i) { |
431 const GURL gurl(resource_prefetch_request_list[i].resource_url); | 431 const GURL gurl(resource_prefetch_request_list[i].resource_url); |
432 // Important security check. Do not remove. | 432 // Important security check. Do not remove. |
433 if (!CanOpenViaFastPath(plugin_instance, gurl)) { | 433 if (!CanOpenViaFastPath(plugin_instance, gurl)) { |
434 resource_prefetch_request_list.clear(); | 434 resource_prefetch_request_list.clear(); |
435 break; | 435 break; |
(...skipping 1273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1709 &StreamPexe | 1709 &StreamPexe |
1710 }; | 1710 }; |
1711 | 1711 |
1712 } // namespace | 1712 } // namespace |
1713 | 1713 |
1714 const PPB_NaCl_Private* GetNaClPrivateInterface() { | 1714 const PPB_NaCl_Private* GetNaClPrivateInterface() { |
1715 return &nacl_interface; | 1715 return &nacl_interface; |
1716 } | 1716 } |
1717 | 1717 |
1718 } // namespace nacl | 1718 } // namespace nacl |
OLD | NEW |