Commit 3a7213dc authored by David Maunder's avatar David Maunder Committed by Commit Bot

Don't close tab if Tab is uninitialized

In backShouldCloseTab we should not try to close the Tab
if the Tab is not initialized.

Bug: 1117396
Change-Id: I7ef0b4e50315ddc9560b438c66a7f66161c5e1ea
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2410920Reviewed-by: default avatarTommy Nyquist <nyquist@chromium.org>
Commit-Queue: David Maunder <davidjm@chromium.org>
Cr-Commit-Position: refs/heads/master@{#808621}
parent ec64ba8c
...@@ -1844,6 +1844,9 @@ public class ChromeTabbedActivity extends ChromeActivity<ChromeActivityComponent ...@@ -1844,6 +1844,9 @@ public class ChromeTabbedActivity extends ChromeActivity<ChromeActivityComponent
*/ */
@Override @Override
public boolean backShouldCloseTab(Tab tab) { public boolean backShouldCloseTab(Tab tab) {
if (!tab.isInitialized()) {
return false;
}
@TabLaunchType @TabLaunchType
int type = tab.getLaunchType(); int type = tab.getLaunchType();
......
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