In WebContentsImpl, make it safe for WebContentsDelegate::AddNewContents
to delete the popup.
The Android implementation of WebContentsDelegate seems to do this sometimes,
so protect against it happening by means of a WeakPtr.
The main crash we've seen has been in ShowCreatedWindow(), but I've
spotted a much more low-volume equivalent that occurs in
CreateNewWindow() as well. This fixes both.
Revert the speculative fixes we previously landed for this bug.
BUG=680876
Review-Url: https://codereview.chromium.org/2675843002
Cr-Commit-Position: refs/heads/master@{#450121}
1 file changed