DescriptionAttempt at fixing crash in menus shown from infobars. Here's what the
current code does when closing an infobar:
. The animation ends, resulting in a delayed deletion of InfoBarView
(InfoBarContainerView::PlatformSpecificRemoveInfoBar).
. The InfoBarDelegate deletes itself (InfoBarDelegate::InfoBarClosed).
. Eventually the InfoBarView is deleted.
This leaves a window of time between which the view is alive, but the
delegate has been deleted. The view doesn't directly reference the
delegate anymore, but the menu models created by the infobarviews
do. This means if a paint comes in to the menu it's going to query the
deleted delegate and we crash.
I made CancelMenu pure virtual in hopes of avoiding this in the future
by making subclasses think about it.
BUG=93314
TEST=make sure menus on infobars still work.
R=pkasting@chromium.org
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=101958
Patch Set 1 #
Total comments: 2
Patch Set 2 : Incorporate review feedback #Patch Set 3 : Promote more code #Patch Set 4 : Change comment and remove change to views #
Total comments: 4
Patch Set 5 : ignore return value #
Total comments: 1
Messages
Total messages: 8 (0 generated)
|