mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-07-07 07:21:18 +12:00
Free BT resources acquired during pairing
This commit is contained in:
parent
f43f88f728
commit
0340e5e7cb
1 changed files with 2 additions and 0 deletions
|
@ -250,9 +250,11 @@ void PairingDialog::WorkerThread()
|
||||||
UpdateCallback(PairingState::SearchFailed);
|
UpdateCallback(PairingState::SearchFailed);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
stdx::scope_exit freeInfo([info]() { bt_free(info);});
|
||||||
|
|
||||||
//! Open dev to read name
|
//! Open dev to read name
|
||||||
const auto hostDesc = hci_open_dev(hostId);
|
const auto hostDesc = hci_open_dev(hostId);
|
||||||
|
stdx::scope_exit freeDev([hostDesc]() { hci_close_dev(hostDesc);});
|
||||||
char nameBuffer[HCI_MAX_NAME_LENGTH] = {};
|
char nameBuffer[HCI_MAX_NAME_LENGTH] = {};
|
||||||
|
|
||||||
// Get device name and compare. Would use product and vendor id from SDP, but many third-party Wiimotes don't store them
|
// Get device name and compare. Would use product and vendor id from SDP, but many third-party Wiimotes don't store them
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue