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

Commit 63d49152 authored by SongFerng Wang's avatar SongFerng Wang Committed by Automerger Merge Worker
Browse files

Merge "[LE Broadcast]Fix the crash in the BluetoothLeBroadcast constructor"...

Merge "[LE Broadcast]Fix the crash in the BluetoothLeBroadcast constructor" into tm-qpr-dev am: 5fa44874 am: 68c5ddf8

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19993858



Change-Id: I8f7ad9b1b680d23c1071da2d7bf7d67abf428281
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 0e4cadfc 68c5ddf8
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -210,13 +210,15 @@ public class LocalBluetoothLeBroadcast implements LocalBluetoothProfile {

    LocalBluetoothLeBroadcast(Context context) {
        mExecutor = Executors.newSingleThreadExecutor();
        BluetoothAdapter.getDefaultAdapter().
                getProfileProxy(context, mServiceListener, BluetoothProfile.LE_AUDIO_BROADCAST);
        mBuilder = new BluetoothLeAudioContentMetadata.Builder();
        mContentResolver = context.getContentResolver();
        Handler handler = new Handler(Looper.getMainLooper());
        mSettingsObserver = new BroadcastSettingsObserver(handler);
        updateBroadcastInfoFromContentProvider();

        // Before registering callback, the constructor should finish creating the all of variables.
        BluetoothAdapter.getDefaultAdapter()
                .getProfileProxy(context, mServiceListener, BluetoothProfile.LE_AUDIO_BROADCAST);
    }

    /**