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

Commit 24072ec1 authored by William Escande's avatar William Escande
Browse files

Gatt: App exception aren't from SystemServer

Calling into mService(IBluetoothGatt) will call the GattService from
Bluetooth app that does not live in the systemServer.
Therefore, exception should be rethrown as runtimeException

Bug: 298264617
Test: atest CtsBluetoothTestCases | Cts does not handled failure in the
      binder nor any of the Test framework we currently have
Change-Id: Ie2ed38e5076242c1001e231f70105890c86ea116
parent a67bdd0c
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1498,7 +1498,7 @@ public final class BluetoothGatt implements BluetoothProfile {
            synchronized (mDeviceBusyLock) {
                mDeviceBusy = false;
            }
            throw e.rethrowFromSystemServer();
            throw e.rethrowAsRuntimeException();
        }

        return requestStatus;
@@ -1641,7 +1641,7 @@ public final class BluetoothGatt implements BluetoothProfile {
            synchronized (mDeviceBusyLock) {
                mDeviceBusy = false;
            }
            e.rethrowFromSystemServer();
            throw e.rethrowAsRuntimeException();
        }
        return BluetoothStatusCodes.ERROR_UNKNOWN;
    }