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

Unified Diff: chrome/renderer/plugins/chrome_plugin_placeholder.cc

Issue 791763003: [DISCARD] While getting plug-in info, use securityOrigin() of the top level frame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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: chrome/renderer/plugins/chrome_plugin_placeholder.cc
diff --git a/chrome/renderer/plugins/chrome_plugin_placeholder.cc b/chrome/renderer/plugins/chrome_plugin_placeholder.cc
index 9aebe5215da662df3e1854dd5562e827041a84b8..bfeca82907874e4621273e608d44bc895809e739 100644
--- a/chrome/renderer/plugins/chrome_plugin_placeholder.cc
+++ b/chrome/renderer/plugins/chrome_plugin_placeholder.cc
@@ -281,8 +281,9 @@ void ChromePluginPlaceholder::OnCancelledDownloadingPlugin() {
void ChromePluginPlaceholder::PluginListChanged() {
if (!GetFrame() || !plugin())
return;
- WebDocument document = GetFrame()->top()->document();
- if (document.isNull())
+ blink::WebSecurityOrigin top_level_origin =
+ GetFrame()->top()->securityOrigin();
+ if (top_level_origin.isNull())
return;
ChromeViewHostMsg_GetPluginInfo_Output output;
@@ -290,7 +291,7 @@ void ChromePluginPlaceholder::PluginListChanged() {
render_frame()->Send(
new ChromeViewHostMsg_GetPluginInfo(routing_id(),
GURL(GetPluginParams().url),
- document.url(),
+ GURL(top_level_origin.toString()),
mime_type,
&output));
if (output.status.value == status_->value)
« no previous file with comments | « chrome/renderer/chrome_content_renderer_client.cc ('k') | chrome/renderer/plugins/shadow_dom_plugin_placeholder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698