Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(548)

Issue 7834013: Fix top crasher on the AvatarMenuButton destructor (Closed)

Created:
9 years, 3 months ago by cpu_(ooo_6.6-7.5)
Modified:
9 years, 3 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Fix top crasher on the AvatarMenuButton destructor like crash/reportdetail?reportid=01290260a34c8b50 Because GetTopLevelWidget() is not valid, in the call GetNativeHandle() { return GetWidget()->GetTopLevelWidget()->GetNativeWindow(); } I see no other solution than to test if the whole window is going away. TBR=ben BUG=95232 TEST= see bug Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=99591

Patch Set 1 #

Total comments: 2

Patch Set 2 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -2 lines) Patch
M chrome/browser/ui/views/avatar_menu_button.cc View 1 2 chunks +4 lines, -2 lines 0 comments Download

Messages

Total messages: 1 (0 generated)
viettrungluu
9 years, 3 months ago (2011-09-04 04:54:01 UTC) #1
LGTM, I suppose. I suspect it'd be cleaner without all the extraneous argument
checking, now that you check for the browser window closing before calling the
function.

http://codereview.chromium.org/7834013/diff/1/chrome/browser/ui/views/avatar_...
File chrome/browser/ui/views/avatar_menu_button.cc (right):

http://codereview.chromium.org/7834013/diff/1/chrome/browser/ui/views/avatar_...
chrome/browser/ui/views/avatar_menu_button.cc:38: if (!bw)
Are these checks (against |bw| and |window|, below) still necessary in this
function? Maybe they should be DCHECK()s?

http://codereview.chromium.org/7834013/diff/1/chrome/browser/ui/views/avatar_...
chrome/browser/ui/views/avatar_menu_button.cc:77: // so the taksbar button will
be removed by windows anyway.
s/taksbar/taskbar

and s/windows/Windows

Powered by Google App Engine
This is Rietveld 408576698