diff options
author | jochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-01-09 11:51:37 +0000 |
---|---|---|
committer | jochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-01-09 11:51:37 +0000 |
commit | b9e37058e910316f53cbfb9bb664cd3509276934 (patch) | |
tree | 41108f283169c05eeb5f46e7b7f7af2c8a0da0d8 /components | |
parent | 2cd768bd7229500e9b2fe025d487e938673124e0 (diff) | |
download | chromium_src-b9e37058e910316f53cbfb9bb664cd3509276934.zip chromium_src-b9e37058e910316f53cbfb9bb664cd3509276934.tar.gz chromium_src-b9e37058e910316f53cbfb9bb664cd3509276934.tar.bz2 |
Don't try to access the plugin_ after we deleted in the in plugin placeholder
BUG=332675
R=bauerb@chromium.org,inferno@chromium.org
Review URL: https://codereview.chromium.org/131073002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243851 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'components')
-rw-r--r-- | components/plugins/renderer/plugin_placeholder.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/components/plugins/renderer/plugin_placeholder.cc b/components/plugins/renderer/plugin_placeholder.cc index 343c7ad..f99ee48 100644 --- a/components/plugins/renderer/plugin_placeholder.cc +++ b/components/plugins/renderer/plugin_placeholder.cc @@ -107,6 +107,8 @@ void PluginPlaceholder::ReplacePlugin(WebPlugin* new_plugin) { void PluginPlaceholder::HidePlugin() { hidden_ = true; + if (!plugin_) + return; WebPluginContainer* container = plugin_->container(); WebElement element = container->element(); element.setAttribute("style", "display: none;"); @@ -158,6 +160,8 @@ void PluginPlaceholder::SetMessage(const base::string16& message) { } void PluginPlaceholder::UpdateMessage() { + if (!plugin_) + return; std::string script = "window.setMessage(" + base::GetQuotedJSONString(message_) + ")"; plugin_->web_view()->mainFrame()->executeScript( |