Chromium Code Reviews
DescriptionMac: Retain the child NSWindow in WidgetOwnerNSWindowAdapter before invoking close
AppKit has gotten better at handling the last reference to an NSWindow
going away inside -[NSWindow close]. However, on 10.9, bad things can
happen if we don't retain the NSWindow being closed until after the
-[NSWindow close] call returns.
WidgetOwnerNSWindowAdapter::OnWindowWillClose() wasn't doing this. The
result: in some codepaths, a zombie access under the close call.
To fix, retain the window being closed.
BUG=616701
TEST=On OSX 10.9, have one browser tab, navigate to a page (e.g.
chrome://version), then press Backspace. The "Press Cmd+Left to go back"
bubble should appear. Wait for it to fade out completely. Then close the
tab via the tabstrip. Chrome shouldn't crash.
Committed: https://crrev.com/6777bcc56aff3a1dc27fb0adced9a462b22e4e33
Cr-Commit-Position: refs/heads/master@{#398890}
Patch Set 1 #Patch Set 2 : Refine DCHECK #
Messages
Total messages: 16 (8 generated)
|
|||||||||||||||||||||||||||||||||||||