commit | a5e8da7b9465e73c579027be9f003678bec07e25 | [log] [tgz] |
---|---|---|
author | Chen Chen <cncn@google.com> | Tue Mar 15 19:33:07 2022 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Tue Mar 15 19:33:07 2022 +0000 |
tree | d59e12288c929c79d07d16f2d4f62d78ee83f92f | |
parent | 0347ea978c45fb02f1933f4098983f162d5f2e6e [diff] | |
parent | a16a0ece1a891eb6db9d1caab704b9b597fd6254 [diff] |
Merge "SpatialAudio: fix crashes in BluetoothAudioSession" am: 8673f8c28f am: 81edd99b87 am: a16a0ece1a Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2025663 Change-Id: I12ec3fe8490489a202195cb05e7cc5a4ee6d9435
diff --git a/bluetooth/audio/utils/aidl_session/BluetoothAudioSession.cpp b/bluetooth/audio/utils/aidl_session/BluetoothAudioSession.cpp index 37ac967..cdee520 100644 --- a/bluetooth/audio/utils/aidl_session/BluetoothAudioSession.cpp +++ b/bluetooth/audio/utils/aidl_session/BluetoothAudioSession.cpp
@@ -431,7 +431,9 @@ std::shared_ptr<PortStatusCallbacks> callback = observer.second; LOG(INFO) << __func__ << " - allowed=" << (allowed ? " allowed" : " disallowed"); - callback->low_latency_mode_allowed_cb_(cookie, allowed); + if (callback->low_latency_mode_allowed_cb_ != nullptr) { + callback->low_latency_mode_allowed_cb_(cookie, allowed); + } } }