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

Commit 3c42838b authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "le_audio/client_audio: Fix deadlock on Stop()" am: b72c48d9 am:...

Merge "le_audio/client_audio: Fix deadlock on Stop()" am: b72c48d9 am: 4471fe52 am: 55b35e5f am: 601149e2

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/1945472

Change-Id: Ia1a8d9243a5fb2755d663c47de289bd1d55ebd62
parents 33dd83e1 601149e2
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -315,12 +315,13 @@ void LeAudioClientAudioSource::Stop() {

  sinkClientInterface->StopSession();
  le_audio_sink_hal_state = HAL_STOPPED;
  std::lock_guard<std::mutex> guard(sinkInterfaceMutex);
  localAudioSinkReceiver = nullptr;

  if (CodecManager::GetInstance()->GetCodecLocation() == CodecLocation::HOST) {
    stop_audio_ticks();
  }

  std::lock_guard<std::mutex> guard(sinkInterfaceMutex);
  localAudioSinkReceiver = nullptr;
}

const void* LeAudioClientAudioSource::Acquire() {