diff options
author | apatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-20 00:12:33 +0000 |
---|---|---|
committer | apatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-20 00:12:33 +0000 |
commit | b7d7ed56d3ca5549b6bee0e277ea17370a847573 (patch) | |
tree | 82280e21ce8d77b6998d41e9fb5eb5f6dafb4a4e /chrome | |
parent | 8e0bbf1a0ad8dc782b7addb93624e4a7ffe2519e (diff) | |
download | chromium_src-b7d7ed56d3ca5549b6bee0e277ea17370a847573.zip chromium_src-b7d7ed56d3ca5549b6bee0e277ea17370a847573.tar.gz chromium_src-b7d7ed56d3ca5549b6bee0e277ea17370a847573.tar.bz2 |
Fix crash in renderer process when Pepper plugin fails to initialize.
Adding a null plugin delegate to current_oldstyle_pepper_plugins_ caused a crash when the element was later dereferenced.
TEST=try
BUG=none
Review URL: http://codereview.chromium.org/2945019
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52967 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/renderer/render_view.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/chrome/renderer/render_view.cc b/chrome/renderer/render_view.cc index fcaa65a..31a355e9 100644 --- a/chrome/renderer/render_view.cc +++ b/chrome/renderer/render_view.cc @@ -3335,6 +3335,9 @@ webkit_glue::WebPluginDelegate* RenderView::CreatePluginDelegate( if (use_pepper_host) { WebPluginDelegatePepper* pepper_plugin = WebPluginDelegatePepper::Create(file_path, mime_type, AsWeakPtr()); + if (!pepper_plugin) + return NULL; + current_oldstyle_pepper_plugins_.insert(pepper_plugin); return pepper_plugin; } else { |