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

Unified Diff: webkit/glue/webframeloaderclient_impl.cc

Issue 60021: An empty MIME type doesn't match any plugin, no matter what they may claim.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 9 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/webframeloaderclient_impl.cc
===================================================================
--- webkit/glue/webframeloaderclient_impl.cc (revision 12907)
+++ webkit/glue/webframeloaderclient_impl.cc (working copy)
@@ -1246,7 +1246,7 @@
// See if the type is handled by an installed plugin, if so, we can show it.
// TODO(beng): (http://b/1085524) This is the place to stick a preference to
// disable full page plugins (optionally for certain types!)
- return plugin_data && plugin_data->supportsMimeType(mime_type);
+ return !mime_type.isEmpty() && plugin_data && plugin_data->supportsMimeType(mime_type);
}
bool WebFrameLoaderClient::representationExistsForURLScheme(const String& URLScheme) const {
@@ -1540,7 +1540,7 @@
// If Chrome is started with the --disable-plugins switch, pluginData is null.
PluginData* plugin_data = webframe_->frame()->page()->pluginData();
- if (plugin_data && plugin_data->supportsMimeType(mime_type))
+ if (!mime_type.isEmpty() && plugin_data && plugin_data->supportsMimeType(mime_type))
jam 2009/04/02 20:31:34 I believe this one isn't needed because of line 15
Pam (message me for reviews) 2009/04/02 20:34:07 Right. Removed.
return ObjectContentNetscapePlugin;
if (MIMETypeRegistry::isSupportedNonImageMIMEType(mime_type))
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698