Merge "Bluetooth: Fix to avoid BluetoothPan ServiceConnection leak" into pi-dev am: d924894652
am: 75787c8a77
Change-Id: Ib111a099149a8a6852f029d5c8b1334ea891a7fc
This commit is contained in:
@@ -127,7 +127,8 @@ public class TetherPreferenceController extends AbstractPreferenceController imp
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
if (mBluetoothAdapter != null) {
|
||||
if (mBluetoothAdapter != null &&
|
||||
mBluetoothAdapter.getState() == BluetoothAdapter.STATE_ON) {
|
||||
mBluetoothAdapter.getProfileProxy(mContext, mBtProfileServiceListener,
|
||||
BluetoothProfile.PAN);
|
||||
}
|
||||
|
Reference in New Issue
Block a user