Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0792ef64 authored by Ajay Kumar's avatar Ajay Kumar Committed by Linux Build Service Account
Browse files

Bluetooth: Avoid the crash in LEScanClients following BT process restart

Due to sudden crash and restart of BT process, BTLEClient object to call
is not valid and throws the NullPointerException.

Change-Id: Ie3b98149e83afc5b84b042ce61978eb1599dce49
CRs-Fixed: 729372
parent 6d5db5e3
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1525,7 +1525,7 @@ public final class BluetoothAdapter {
                if (VDBG) Log.d(TAG, "onBluetoothServiceDown: " + mService);
                synchronized (mManagerCallback) {
                    mService = null;
                    mLeScanClients.clear();
                    if (mLeScanClients != null) mLeScanClients.clear();
                    if (sBluetoothLeAdvertiser != null) sBluetoothLeAdvertiser.cleanup();
                    if (sBluetoothLeScanner != null) sBluetoothLeScanner.cleanup();
                    for (IBluetoothManagerCallback cb : mProxyServiceStateCallbacks ){