commit | a6dcbb823a6e138661edbaa657e946cf7e10d39f | [log] [tgz] |
---|---|---|
author | Xiaoqian Dai <xdai@chromium.org> | Mon May 20 17:28:26 2019 |
committer | Commit Bot <commit-bot@chromium.org> | Mon May 20 17:28:26 2019 |
tree | 5a6e114a750942fd003c67dc38f92eccacba1125 | |
parent | b8ce5f07b2f49c34ece300d7c5ceb7313da50f48 [diff] |
Add CHECKs to help investigate crbug.com/937381. From the crash stack, |Widget::widget_delegate_| has been deleted but not set to nullptr, thus caused the nullptr dereference crash. However, we did not find the equivalent number of crashes in WidgetDelegate::~WidgetDelegate(). This CL does: 1) Change DCHECK to CHECK in Widget::~Widget() when NATIVE_WIDGET_OWNS_WIDGET to see if we can get another crash stack to help investigate the bug. If crashes happen here, means Widget is destroyed while its native widget is still alive, thus Widget::OnNativeWidgetDestroyed() is not called, thus |widget_delegate_| is not set to nullptr. 2) Besides that, it may be also possible that a window is destroyed while building up the mru window. We added a scoped window observer to observe window in IsWindowConsideredActivatable() and see if there is any window is destroyed out from the function. Bug: 937381 Change-Id: I01172cc36fcb19078a5d416d7c87fb505f6304d7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1615384 Commit-Queue: Xiaoqian Dai <xdai@chromium.org> Reviewed-by: Scott Violet <sky@chromium.org> Cr-Commit-Position: refs/heads/master@{#661386}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .