New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 760722 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner: ----
Closed: Aug 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug



Sign in to add a comment

Tether can be connected to two devices simultanously

Project Member Reported by lesliewatkins@chromium.org, Aug 30 2017

Issue description

OS: CrOS

What steps will reproduce the problem?
(1) Sign into Chromebook and two phones with the same account.
(2) Two entries should appear in the Mobile Data section of the System Tray.
(3) Connect to one of the networks. Wait for the connection to complete. (e.g. It should say "Connected", not "Connecting...")
(4) Connect to the other network.

What is the expected result?
The first network should disconnect and the second one should connect.

What happens instead?
The first network never disconnects, so there are two Tether connections.
 
Screenshot 2017-08-30 at 1.05.46 PM.png
7.4 KB View Download
pa_logs_two_connections.txt
93.3 KB View Download
Labels: M-61
Status: Available (was: Untriaged)
Leslie: What happened when you were in this state? Could you still use the internet? What happens if you try to disconnect from the network that you're not truly connected to?

IMO, it seems like there is a race condition in TetherConnector, and we need to invalidate weak pointers in CancelConnectionAttempt().
I can still use the internet.

If I try to disconnect from the second network I get the error:

"Disconnect requested for Tether network with GUID ... but no device is connected."

The network appears to remain connected in Settings and the System Tray.
Cc: pbath...@chromium.org rjahagir@chromium.org
Status: Started (was: Available)
Project Member

Comment 6 by bugdroid1@chromium.org, Aug 31 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1281ec36b6436879d371b5f05c18e65bc5806955

commit 1281ec36b6436879d371b5f05c18e65bc5806955
Author: Kyle Horimoto <khorimoto@google.com>
Date: Thu Aug 31 20:04:41 2017

[CrOS Tether] Disallow more than one connected host.

This fixes an issue in which if the user connects to one device, then
connects to another without disconnecting from the first one, both
devices would appear as "Connected" in the UI. They were not actually
both connected, of course, but this UI is very confusing to users.

Now, when we receive a request to connect to a host, we check to see if
another host is already connected. If so, we disconnect from that one
before continuing.

Note: This CL also creates a pure virtual TetherConnector class and
moves the existing code to TetherConnectorImpl. This greatly aids in
testability because TetherConnectorImpl has so many dependencies.

Bug:  760722 , 672263
Change-Id: If42e3944b29bef17e4198703738211a96649df8c
Reviewed-on: https://chromium-review.googlesource.com/644774
Commit-Queue: Kyle Horimoto <khorimoto@chromium.org>
Reviewed-by: Steven Bennetts <stevenjb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#498964}
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/BUILD.gn
[add] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/fake_tether_connector.cc
[add] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/fake_tether_connector.h
[add] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/fake_tether_disconnector.cc
[add] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/fake_tether_disconnector.h
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/initializer_impl.cc
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/network_connection_handler_tether_delegate.cc
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/network_connection_handler_tether_delegate.h
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/network_connection_handler_tether_delegate_unittest.cc
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/tether_connector.h
[rename] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/tether_connector_impl.cc
[add] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/tether_connector_impl.h
[rename] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/tether_connector_impl_unittest.cc
[modify] https://crrev.com/1281ec36b6436879d371b5f05c18e65bc5806955/chromeos/components/tether/tether_disconnector_impl_unittest.cc

Labels: Merge-Request-61
Project Member

Comment 8 by sheriffbot@chromium.org, Aug 31 2017

Labels: -Merge-Request-61 Merge-Review-61 Hotlist-Merge-Review
This bug requires manual review: We are only 4 days from stable.
Please contact the milestone owner if you have questions.
Owners: amineer@(Android), cmasso@(iOS), ketakid@(ChromeOS), govind@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 9 by ketakid@google.com, Aug 31 2017

Labels: -Merge-Review-61 Merge-Approved-61
Approving merge to M61.
Project Member

Comment 10 by bugdroid1@chromium.org, Aug 31 2017

Labels: -merge-approved-61 merge-merged-3163
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a

commit ee6aee66d699fb9a176ba2b3b7d4ab971a88932a
Author: Kyle Horimoto <khorimoto@google.com>
Date: Thu Aug 31 21:48:58 2017

[CrOS Tether] Disallow more than one connected host.

This fixes an issue in which if the user connects to one device, then
connects to another without disconnecting from the first one, both
devices would appear as "Connected" in the UI. They were not actually
both connected, of course, but this UI is very confusing to users.

Now, when we receive a request to connect to a host, we check to see if
another host is already connected. If so, we disconnect from that one
before continuing.

Note: This CL also creates a pure virtual TetherConnector class and
moves the existing code to TetherConnectorImpl. This greatly aids in
testability because TetherConnectorImpl has so many dependencies.

TBR=khorimoto@google.com

(cherry picked from commit 1281ec36b6436879d371b5f05c18e65bc5806955)

Bug:  760722 , 672263
Change-Id: If42e3944b29bef17e4198703738211a96649df8c
Reviewed-on: https://chromium-review.googlesource.com/644774
Commit-Queue: Kyle Horimoto <khorimoto@chromium.org>
Reviewed-by: Steven Bennetts <stevenjb@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#498964}
Reviewed-on: https://chromium-review.googlesource.com/646847
Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
Cr-Commit-Position: refs/branch-heads/3163@{#1051}
Cr-Branched-From: ff259bab28b35d242e10186cd63af7ed404fae0d-refs/heads/master@{#488528}
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/BUILD.gn
[add] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/fake_tether_connector.cc
[add] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/fake_tether_connector.h
[add] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/fake_tether_disconnector.cc
[add] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/fake_tether_disconnector.h
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/initializer_impl.cc
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/network_connection_handler_tether_delegate.cc
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/network_connection_handler_tether_delegate.h
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/network_connection_handler_tether_delegate_unittest.cc
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/tether_connector.h
[rename] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/tether_connector_impl.cc
[add] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/tether_connector_impl.h
[rename] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/tether_connector_impl_unittest.cc
[modify] https://crrev.com/ee6aee66d699fb9a176ba2b3b7d4ab971a88932a/chromeos/components/tether/tether_disconnector_impl_unittest.cc

Status: Fixed (was: Started)

Comment 12 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Comment 13 by dchan@chromium.org, Jan 23 2018

Status: Fixed (was: Archived)

Sign in to add a comment