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

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

Merge "BTAudio HAL: Init and check for factory provider" am: 517dc8b6 am:...

Merge "BTAudio HAL: Init and check for factory provider" am: 517dc8b6 am: 48a0f76c am: 39da9ed9

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



Change-Id: I57427896a5abb31c30034c890851136b6e4bd949
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 16caad34 39da9ed9
Loading
Loading
Loading
Loading
+3 −2
Original line number Original line Diff line number Diff line
@@ -46,6 +46,7 @@ std::ostream& operator<<(std::ostream& os, const BluetoothAudioCtrlAck& ack) {
BluetoothAudioClientInterface::BluetoothAudioClientInterface(
BluetoothAudioClientInterface::BluetoothAudioClientInterface(
    IBluetoothTransportInstance* instance)
    IBluetoothTransportInstance* instance)
    : provider_(nullptr),
    : provider_(nullptr),
      provider_factory_(nullptr),
      session_started_(false),
      session_started_(false),
      data_mq_(nullptr),
      data_mq_(nullptr),
      transport_(instance) {
      transport_(instance) {
@@ -154,7 +155,7 @@ BluetoothAudioSinkClientInterface::BluetoothAudioSinkClientInterface(
}
}


BluetoothAudioSinkClientInterface::~BluetoothAudioSinkClientInterface() {
BluetoothAudioSinkClientInterface::~BluetoothAudioSinkClientInterface() {
  if (provider_ != nullptr) {
  if (provider_factory_ != nullptr) {
    AIBinder_unlinkToDeath(provider_factory_->asBinder().get(), death_recipient_.get(),
    AIBinder_unlinkToDeath(provider_factory_->asBinder().get(), death_recipient_.get(),
                           nullptr);
                           nullptr);
  }
  }
@@ -168,7 +169,7 @@ BluetoothAudioSourceClientInterface::BluetoothAudioSourceClientInterface(
}
}


BluetoothAudioSourceClientInterface::~BluetoothAudioSourceClientInterface() {
BluetoothAudioSourceClientInterface::~BluetoothAudioSourceClientInterface() {
  if (provider_ != nullptr) {
  if (provider_factory_ != nullptr) {
    AIBinder_unlinkToDeath(provider_factory_->asBinder().get(), death_recipient_.get(),
    AIBinder_unlinkToDeath(provider_factory_->asBinder().get(), death_recipient_.get(),
                           nullptr);
                           nullptr);
  }
  }