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

Unified Diff: content/browser/intents/intent_injector.cc

Issue 11026070: Add API to construct new vector interchange MIME data type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Improve comment Created 8 years, 2 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
« no previous file with comments | « no previous file | content/content_tests.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/intents/intent_injector.cc
diff --git a/content/browser/intents/intent_injector.cc b/content/browser/intents/intent_injector.cc
index 664576072f74d178c5666772a73fcb13cb243c18..28cd1e2aca6cd95bc9f4b6dea430e91e6c2b2f2b 100644
--- a/content/browser/intents/intent_injector.cc
+++ b/content/browser/intents/intent_injector.cc
@@ -82,8 +82,11 @@ void IntentInjector::RenderViewCreated(RenderViewHost* render_view_host) {
return;
}
- if (source_intent_->data_type == webkit_glue::WebIntentData::BLOB) {
- // Grant read permission on the blob file to the delivered context.
+ // If we're passing a browser-originated blob, either directly or as part of a
+ // payload, grant read permission on the blob file to the delivered context.
+ if (source_intent_->data_type == webkit_glue::WebIntentData::BLOB ||
+ (source_intent_->data_type == webkit_glue::WebIntentData::MIME_TYPE &&
+ !source_intent_->blob_file.empty())) {
const int child_id = render_view_host->GetProcess()->GetID();
ChildProcessSecurityPolicy* policy =
ChildProcessSecurityPolicy::GetInstance();
« no previous file with comments | « no previous file | content/content_tests.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698