Index: chrome/browser/renderer_host/resource_message_filter.cc |
diff --git a/chrome/browser/renderer_host/resource_message_filter.cc b/chrome/browser/renderer_host/resource_message_filter.cc |
index 698e385f301b33d4815629d4372d9a29a783c497..25bd8c0fcea1c4861b200a191fff3831e98aedbb 100644 |
--- a/chrome/browser/renderer_host/resource_message_filter.cc |
+++ b/chrome/browser/renderer_host/resource_message_filter.cc |
@@ -477,7 +477,7 @@ bool ResourceMessageFilter::OnMessageReceived(const IPC::Message& msg) { |
IPC_MESSAGE_HANDLER(ViewHostMsg_PreCacheFont, OnPreCacheFont) |
#endif |
IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_GetPlugins, OnGetPlugins) |
- IPC_MESSAGE_HANDLER(ViewHostMsg_GetPluginPath, OnGetPluginPath) |
+ IPC_MESSAGE_HANDLER(ViewHostMsg_GetPluginInfo, OnGetPluginInfo) |
IPC_MESSAGE_HANDLER(ViewHostMsg_DownloadUrl, OnDownloadUrl) |
IPC_MESSAGE_HANDLER_GENERIC(ViewHostMsg_ContextMenu, |
OnReceiveContextMenuMsg(msg)) |
@@ -801,13 +801,22 @@ void ResourceMessageFilter::OnGetPluginsOnFileThread( |
NewRunnableMethod(this, &ResourceMessageFilter::Send, reply_msg)); |
} |
-void ResourceMessageFilter::OnGetPluginPath(const GURL& url, |
+void ResourceMessageFilter::OnGetPluginInfo(const GURL& url, |
const GURL& policy_url, |
const std::string& mime_type, |
- FilePath* filename, |
- std::string* url_mime_type) { |
- *filename = plugin_service_->GetPluginPath( |
- url, policy_url, mime_type, url_mime_type); |
+ bool* found, |
+ WebPluginInfo* info, |
+ std::string* actual_mime_type) { |
+ bool allow_wildcard = true; |
+ *found = NPAPI::PluginList::Singleton()->GetPluginInfo(url, |
+ mime_type, |
+ allow_wildcard, |
+ info, |
+ actual_mime_type); |
+ if (*found) { |
+ info->enabled = info->enabled && |
+ plugin_service_->PrivatePluginAllowedForURL(info->path, policy_url); |
+ } |
} |
void ResourceMessageFilter::OnOpenChannelToPlugin(const GURL& url, |