bluez5: minor error handling etc. fixups

This commit is contained in:
Pauli Virtanen 2021-09-04 17:13:08 +03:00 committed by Wim Taymans
parent 44f10330e8
commit 18dde01d87
3 changed files with 15 additions and 4 deletions

View file

@ -713,7 +713,8 @@ static void emit_node_info(struct impl *this, bool full)
{ "media.name", ((this->transport && this->transport->device->name) ?
this->transport->device->name : "HSP/HFP") },
};
bool is_ag = (this->transport->profile & SPA_BT_PROFILE_HEADSET_AUDIO_GATEWAY);
bool is_ag = this->transport &&
(this->transport->profile & SPA_BT_PROFILE_HEADSET_AUDIO_GATEWAY);
uint64_t old = full ? this->info.change_mask : 0;
if (full)