diff options
| -rw-r--r-- | packages/SettingsLib/src/com/android/settingslib/bluetooth/CachedBluetoothDeviceManager.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/packages/SettingsLib/src/com/android/settingslib/bluetooth/CachedBluetoothDeviceManager.java b/packages/SettingsLib/src/com/android/settingslib/bluetooth/CachedBluetoothDeviceManager.java index 221836b02347..f741f655bf7c 100644 --- a/packages/SettingsLib/src/com/android/settingslib/bluetooth/CachedBluetoothDeviceManager.java +++ b/packages/SettingsLib/src/com/android/settingslib/bluetooth/CachedBluetoothDeviceManager.java @@ -390,7 +390,10 @@ public class CachedBluetoothDeviceManager { Log.d(TAG, "Bond " + device.getAnonymizedAddress() + " by CSIP"); mOngoingSetMemberPair = device; syncConfigFromMainDevice(device, groupId); - device.createBond(BluetoothDevice.TRANSPORT_LE); + if (!device.createBond(BluetoothDevice.TRANSPORT_LE)) { + Log.d(TAG, "Bonding could not be started"); + mOngoingSetMemberPair = null; + } } private void syncConfigFromMainDevice(BluetoothDevice device, int groupId) { |