Merge "Add future consideration for USB rndis notification handling" into oc-dr1-dev

am: 15fbf9786d

Change-Id: If6afe1cdce9995251ba53fbf30acf9d6e31f9433
This commit is contained in:
Erik Kline
2017-08-09 19:40:54 +00:00
committed by android-build-merger

View File

@@ -834,6 +834,16 @@ public class Tethering extends BaseNetworkObserver {
// For more explanation, see b/62552150 .
synchronized (Tethering.this.mPublicSync) {
// Always record the state of RNDIS.
// TODO: consider:
// final boolean disconnected = !usbConnected;
// if (disconnected) {
// mRndisEnabled = false;
// mUsbTetherRequested = false;
// return;
// }
// final boolean configured = usbConnected && usbConfigured;
// mRndisEnabled = configured ? rndisEnabled : false;
// if (!configured) return;
mRndisEnabled = rndisEnabled;
if (usbConnected && !usbConfigured) {