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

Commit 39ee96b7 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "Bluetooth: Cleaning up sap service object to avoid serviceRecord leaks"

parents 52d844e6 41285ed8
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -120,6 +120,7 @@ public final class BluetoothSap implements BluetoothProfile {
        synchronized (mConnection) {
            if ( mSapService != null) {
                try {
                    mSapService.cleanup();
                    mSapService = null;
                    mContext.unbindService(mConnection);
                } catch (Exception re) {
@@ -150,6 +151,7 @@ public final class BluetoothSap implements BluetoothProfile {
                synchronized (mConnection) {
                    if ( mSapService != null) {
                        try {
                            mSapService.cleanup();
                            mSapService = null;
                            mContext.unbindService(mConnection);
                        } catch (Exception re) {
+1 −0
Original line number Diff line number Diff line
@@ -37,6 +37,7 @@ import android.bluetooth.BluetoothDevice;
 */
interface IBluetoothSap {
    // Public API
    boolean cleanup();
    boolean disconnect(in BluetoothDevice device);
    int getConnectionState(in BluetoothDevice device);
    List<BluetoothDevice> getConnectedDevices();