From bab44ba4d991eb71e696cad6afacf21d0bf1b1e8 Mon Sep 17 00:00:00 2001 From: "jcampan@chromium.org" Date: Fri, 27 Feb 2009 01:59:45 +0000 Subject: An attempt at fixing a crasher reported from the field. BUG=5549 R=sky Review URL: http://codereview.chromium.org/27229 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10565 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/views/view.cc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'chrome/views') diff --git a/chrome/views/view.cc b/chrome/views/view.cc index c7bb123..d435ddb 100644 --- a/chrome/views/view.cc +++ b/chrome/views/view.cc @@ -1172,7 +1172,10 @@ void View::RestoreFloatingViewFocus() { restore_focus_view_task_ = NULL; should_restore_focus_ = false; - GetFocusManager()->RestoreFocusedView(); + FocusManager* focus_manager = GetFocusManager(); + DCHECK(focus_manager); + if (focus_manager) + focus_manager->RestoreFocusedView(); } // static -- cgit v1.1