| Index: chrome/browser/ui/views/frame/browser_view.cc
|
| diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc
|
| index a9ae54db735e788cbf0ca75f07b00e477a07b553..348db6ce3d4d5fbf945925d470c27543b914dd73 100644
|
| --- a/chrome/browser/ui/views/frame/browser_view.cc
|
| +++ b/chrome/browser/ui/views/frame/browser_view.cc
|
| @@ -642,6 +642,11 @@ bool BrowserView::IsAlwaysOnTop() const {
|
| }
|
|
|
| gfx::NativeWindow BrowserView::GetNativeWindow() {
|
| + // While the browser destruction is going on, the widget can already be gone,
|
| + // but utility functions like FindBrowserWithWindow will come here and crash.
|
| + // We short circuit therefore.
|
| + if (!GetWidget())
|
| + return NULL;
|
| return GetWidget()->GetTopLevelWidget()->GetNativeWindow();
|
| }
|
|
|
|
|