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

Unified Diff: ppapi/native_client/src/trusted/plugin/plugin.cc

Issue 9159037: Use CORS for fetching NaCl resources from extensions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add webkit bug# Created 8 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/native_client/src/trusted/plugin/plugin.cc
diff --git a/ppapi/native_client/src/trusted/plugin/plugin.cc b/ppapi/native_client/src/trusted/plugin/plugin.cc
index 6f1949d3f022771b7d499b6a915ab75bffbd321c..f92945d766f1014bd29a880d4ee1cf38aa884f92 100644
--- a/ppapi/native_client/src/trusted/plugin/plugin.cc
+++ b/ppapi/native_client/src/trusted/plugin/plugin.cc
@@ -951,8 +951,7 @@ bool Plugin::Init(uint32_t argc, const char* argn[], const char* argv[]) {
manifest_url = LookupArgument(kNaClManifestAttribute);
// For content handlers the NEXE runs in the security context of the
// content it is rendering and the NEXE itself appears to be a
- // cross-origin resource stored in a Chrome extension. We request
- // universal access during the NEXE load so that we can read the NEXE.
+ // cross-origin resource stored in a Chrome extension.
}
// Use the document URL as the base for resolving relative URLs to find the
// manifest. This takes into account the setting of <base> tags that
@@ -1639,7 +1638,6 @@ void Plugin::ProcessNaClManifest(const nacl::string& manifest_json) {
CHECK(
nexe_downloader_.Open(program_url,
DOWNLOAD_TO_FILE,
- NexeIsContentHandler(),
open_callback,
&UpdateDownloadProgress));
return;
@@ -1681,7 +1679,6 @@ void Plugin::RequestNaClManifest(const nacl::string& url) {
// Will always call the callback on success or failure.
CHECK(nexe_downloader_.Open(nmf_resolved_url.AsString(),
DOWNLOAD_TO_BUFFER,
- NexeIsContentHandler(),
open_callback,
NULL));
} else {
@@ -1690,7 +1687,6 @@ void Plugin::RequestNaClManifest(const nacl::string& url) {
// Will always call the callback on success or failure.
CHECK(nexe_downloader_.Open(nmf_resolved_url.AsString(),
DOWNLOAD_TO_FILE,
- NexeIsContentHandler(),
open_callback,
NULL));
}
@@ -1761,10 +1757,8 @@ int32_t Plugin::GetPOSIXFileDesc(const nacl::string& url) {
bool Plugin::StreamAsFile(const nacl::string& url,
- bool permits_extension_urls,
PP_CompletionCallback callback) {
- PLUGIN_PRINTF(("Plugin::StreamAsFile (url='%s', permits_extension_urls=%d)\n",
- url.c_str(), permits_extension_urls));
+ PLUGIN_PRINTF(("Plugin::StreamAsFile (url='%s')\n", url.c_str()));
FileDownloader* downloader = new FileDownloader();
downloader->Initialize(this);
url_downloaders_.insert(downloader);
@@ -1785,7 +1779,6 @@ bool Plugin::StreamAsFile(const nacl::string& url,
// If true, will always call the callback on success or failure.
return downloader->Open(url,
DOWNLOAD_TO_FILE,
- permits_extension_urls || NexeIsContentHandler(),
open_callback,
&UpdateDownloadProgress);
}
« no previous file with comments | « ppapi/native_client/src/trusted/plugin/plugin.h ('k') | ppapi/native_client/src/trusted/plugin/pnacl_coordinator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698