| OLD | NEW |
| 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 #include "ppapi/native_client/src/trusted/plugin/pnacl_coordinator.h" | 5 #include "ppapi/native_client/src/trusted/plugin/pnacl_coordinator.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "native_client/src/include/checked_cast.h" | 10 #include "native_client/src/include/checked_cast.h" |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 UNREFERENCED_PARAMETER(full_url); | 49 UNREFERENCED_PARAMETER(full_url); |
| 50 UNREFERENCED_PARAMETER(pnacl_options); | 50 UNREFERENCED_PARAMETER(pnacl_options); |
| 51 UNREFERENCED_PARAMETER(uses_nonsfi_mode); | 51 UNREFERENCED_PARAMETER(uses_nonsfi_mode); |
| 52 UNREFERENCED_PARAMETER(error_info); | 52 UNREFERENCED_PARAMETER(error_info); |
| 53 PLUGIN_PRINTF(("PnaclManifest does not contain a program\n")); | 53 PLUGIN_PRINTF(("PnaclManifest does not contain a program\n")); |
| 54 error_info->SetReport(PP_NACL_ERROR_MANIFEST_GET_NEXE_URL, | 54 error_info->SetReport(PP_NACL_ERROR_MANIFEST_GET_NEXE_URL, |
| 55 "pnacl manifest does not contain a program."); | 55 "pnacl manifest does not contain a program."); |
| 56 return false; | 56 return false; |
| 57 } | 57 } |
| 58 | 58 |
| 59 virtual bool GetFileKeys(std::set<nacl::string>* keys) const { | |
| 60 // Does not support enumeration. | |
| 61 PLUGIN_PRINTF(("PnaclManifest does not support key enumeration\n")); | |
| 62 UNREFERENCED_PARAMETER(keys); | |
| 63 return false; | |
| 64 } | |
| 65 | |
| 66 virtual bool ResolveKey(const nacl::string& key, | 59 virtual bool ResolveKey(const nacl::string& key, |
| 67 nacl::string* full_url, | 60 nacl::string* full_url, |
| 68 PP_PNaClOptions* pnacl_options, | 61 PP_PNaClOptions* pnacl_options, |
| 69 ErrorInfo* error_info) const { | 62 ErrorInfo* error_info) const { |
| 70 // All of the component files are native (do not require pnacl translate). | 63 // All of the component files are native (do not require pnacl translate). |
| 71 pnacl_options->translate = PP_FALSE; | 64 pnacl_options->translate = PP_FALSE; |
| 72 // We can only resolve keys in the files/ namespace. | 65 // We can only resolve keys in the files/ namespace. |
| 73 const nacl::string kFilesPrefix = "files/"; | 66 const nacl::string kFilesPrefix = "files/"; |
| 74 size_t files_prefix_pos = key.find(kFilesPrefix); | 67 size_t files_prefix_pos = key.find(kFilesPrefix); |
| 75 if (files_prefix_pos == nacl::string::npos) { | 68 if (files_prefix_pos == nacl::string::npos) { |
| (...skipping 606 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 682 temp_nexe_file_.get(), | 675 temp_nexe_file_.get(), |
| 683 invalid_desc_wrapper_.get(), | 676 invalid_desc_wrapper_.get(), |
| 684 &error_info_, | 677 &error_info_, |
| 685 resources_.get(), | 678 resources_.get(), |
| 686 &pnacl_options_, | 679 &pnacl_options_, |
| 687 this, | 680 this, |
| 688 plugin_); | 681 plugin_); |
| 689 } | 682 } |
| 690 | 683 |
| 691 } // namespace plugin | 684 } // namespace plugin |
| OLD | NEW |