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

Commit 0ba3cfaa authored by Jaikumar Ganesh's avatar Jaikumar Ganesh
Browse files

Fix NullPointerException when checking if its a sinkDevice.

parent 0326beef
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -188,12 +188,14 @@ public class BluetoothA2dpService extends IBluetoothA2dp.Stub {
    private boolean isSinkDevice(String address) {
        String uuids[] = mBluetoothService.getRemoteUuids(address);
        UUID uuid;
        if (uuids != null) {
            for (String deviceUuid: uuids) {
                uuid = UUID.fromString(deviceUuid);
                if (BluetoothUuid.isAudioSink(uuid)) {
                    return true;
                }
            }
        }
        return false;
    }