Commit c6181c44 authored by Dave Tapuska's avatar Dave Tapuska Committed by Commit Bot

Add a CHECK to ensure that widget_base is destroyed correctly.

I suspect something odd is going on with RenderDocument not marking the
Frame as detached. Marking the frame as detached Closes the
WebFrameWidgetBase via RenderWidget::CloseForFrame.

Turn this into a strong assert (there already is a DCHECK in
RenderWidget) that asserts the same thing.

BUG=1139104

Change-Id: If164f299a2fa9964747556dee38216f7ff78a799
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2487705
Commit-Queue: Dave Tapuska <dtapuska@chromium.org>
Reviewed-by: default avatardanakj <danakj@chromium.org>
Cr-Commit-Position: refs/heads/master@{#819191}
parent 1481d062
......@@ -183,7 +183,13 @@ WebFrameWidgetBase::WebFrameWidgetBase(
ThreadScheduler::Current()->DeprecatedDefaultTaskRunner());
}
WebFrameWidgetBase::~WebFrameWidgetBase() = default;
WebFrameWidgetBase::~WebFrameWidgetBase() {
// Ensure that Close is called and we aren't releasing |widget_base_| in the
// destructor.
// TODO(crbug.com/1139104): This CHECK can be changed to a DCHECK once
// the issue is solved.
CHECK(!widget_base_);
}
void WebFrameWidgetBase::BindLocalRoot(WebLocalFrame& local_root) {
local_root_ = To<WebLocalFrameImpl>(local_root);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment