Skip to content
Snippets Groups Projects
Commit 1cde03f6 authored by Łukasz Rymanowski's avatar Łukasz Rymanowski
Browse files

audio_hal_interface: Fix WriteOutData command

provider_ represents HAL 2.0. What we need here is check if any provider
is available. IsValid() does it.

Bug: 150670922
Tag: #feature
Sponsor: jpawlowski@
Test: compile
Change-Id: I37833cdc65dd3a0ce22e01e8886558ca0168e0d0
parent 3213a372
No related branches found
No related tags found
No related merge requests found
......@@ -1060,8 +1060,8 @@ void BluetoothAudioClientInterface::RenewAudioProviderAndSession() {
size_t BluetoothAudioSourceClientInterface::WriteAudioData(const uint8_t* p_buf,
uint32_t len) {
if (provider_ == nullptr) {
LOG(ERROR) << __func__ << ": BluetoothAudioHal nullptr";
if (!IsValid()) {
LOG(ERROR) << __func__ << ": BluetoothAudioHal is not valid";
return 0;
}
if (p_buf == nullptr || len == 0) return 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment