diff options
author | mpcomplete@chromium.org <mpcomplete@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-07 00:26:44 +0000 |
---|---|---|
committer | mpcomplete@chromium.org <mpcomplete@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-07 00:26:44 +0000 |
commit | 67914035cd44f21216a99a54c91ba7faf5408ee0 (patch) | |
tree | c9f4dbbda517fbf1afddfcdf54002a5f1d4f0a65 | |
parent | aaf445dc29da0899bcd2fdd8a966ab6dc18b4734 (diff) | |
download | chromium_src-67914035cd44f21216a99a54c91ba7faf5408ee0.zip chromium_src-67914035cd44f21216a99a54c91ba7faf5408ee0.tar.gz chromium_src-67914035cd44f21216a99a54c91ba7faf5408ee0.tar.bz2 |
Add NULL-checks to render_view_host->view() to fix startup test crash.
TBR=erikkay
Review URL: http://codereview.chromium.org/258040
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28202 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/cocoa/extension_view_mac.mm | 2 | ||||
-rw-r--r-- | chrome/browser/gtk/extension_view_gtk.cc | 2 | ||||
-rw-r--r-- | chrome/browser/views/extensions/extension_view.cc | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/chrome/browser/cocoa/extension_view_mac.mm b/chrome/browser/cocoa/extension_view_mac.mm index 53db3f2..c9844b3 100644 --- a/chrome/browser/cocoa/extension_view_mac.mm +++ b/chrome/browser/cocoa/extension_view_mac.mm @@ -60,7 +60,7 @@ void ExtensionViewMac::UpdatePreferredWidth(int pref_width) { } void ExtensionViewMac::RenderViewCreated() { - if (!pending_background_.empty()) { + if (!pending_background_.empty() && render_view_host()->view()) { render_widget_host_view_->SetBackground(pending_background_); pending_background_.reset(); } diff --git a/chrome/browser/gtk/extension_view_gtk.cc b/chrome/browser/gtk/extension_view_gtk.cc index 2f3d48d..55f7883 100644 --- a/chrome/browser/gtk/extension_view_gtk.cc +++ b/chrome/browser/gtk/extension_view_gtk.cc @@ -49,7 +49,7 @@ void ExtensionViewGtk::CreateWidgetHostView() { } void ExtensionViewGtk::RenderViewCreated() { - if (!pending_background_.empty()) { + if (!pending_background_.empty() && render_view_host()->view()) { render_widget_host_view_->SetBackground(pending_background_); pending_background_.reset(); } diff --git a/chrome/browser/views/extensions/extension_view.cc b/chrome/browser/views/extensions/extension_view.cc index 2915235..f59d1a4 100644 --- a/chrome/browser/views/extensions/extension_view.cc +++ b/chrome/browser/views/extensions/extension_view.cc @@ -163,7 +163,7 @@ void ExtensionView::HandleMouseLeave() { } void ExtensionView::RenderViewCreated() { - if (!pending_background_.empty()) { + if (!pending_background_.empty() && render_view_host()->view()) { render_view_host()->view()->SetBackground(pending_background_); pending_background_.reset(); } |