diff options
author | Sven Gothel <[email protected]> | 2020-09-24 09:53:20 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2020-09-24 09:53:20 +0200 |
commit | 46fde35753eb584f643ea66eb0078ee3281bd18d (patch) | |
tree | b2a18447e8772e65c1a3178e3f5dce786202fe53 /src | |
parent | a2096bf3baf8fb5fc8ed37ce4bdb1ec1112b6e8d (diff) |
HCIHandler::disconnect(): Drop notion of 'ioErrorCause' as it is no more used, moved up to DBTDevice::disconnect()
Diffstat (limited to 'src')
-rw-r--r-- | src/direct_bt/DBTDevice.cpp | 2 | ||||
-rw-r--r-- | src/direct_bt/HCIHandler.cpp | 7 |
2 files changed, 4 insertions, 5 deletions
diff --git a/src/direct_bt/DBTDevice.cpp b/src/direct_bt/DBTDevice.cpp index cf5f2867..a42904c1 100644 --- a/src/direct_bt/DBTDevice.cpp +++ b/src/direct_bt/DBTDevice.cpp @@ -462,7 +462,7 @@ HCIStatusCode DBTDevice::disconnect(const bool fromDisconnectCB, const bool ioEr goto exit; } - res = hci->disconnect(ioErrorCause, hciConnHandle.load(), address, addressType, reason); + res = hci->disconnect(hciConnHandle.load(), address, addressType, reason); if( HCIStatusCode::SUCCESS != res ) { ERR_PRINT("DBTDevice::disconnect: status %s, handle 0x%X, isConnected %d/%d, fromDisconnectCB %d, ioError %d: errno %d %s on %s", getHCIStatusCodeString(res).c_str(), hciConnHandle.load(), diff --git a/src/direct_bt/HCIHandler.cpp b/src/direct_bt/HCIHandler.cpp index 7ad813f8..a1f035f8 100644 --- a/src/direct_bt/HCIHandler.cpp +++ b/src/direct_bt/HCIHandler.cpp @@ -677,8 +677,7 @@ HCIStatusCode HCIHandler::create_conn(const EUI48 &bdaddr, return status; } -HCIStatusCode HCIHandler::disconnect(const bool ioErrorCause, - const uint16_t conn_handle, const EUI48 &peer_bdaddr, const BDAddressType peer_mac_type, +HCIStatusCode HCIHandler::disconnect(const uint16_t conn_handle, const EUI48 &peer_bdaddr, const BDAddressType peer_mac_type, const HCIStatusCode reason) noexcept { const std::lock_guard<std::recursive_mutex> lock(mtx); // RAII-style acquire and relinquish via destructor @@ -708,10 +707,10 @@ HCIStatusCode HCIHandler::disconnect(const bool ioErrorCause, return HCIStatusCode::INVALID_HCI_COMMAND_PARAMETERS; } } - DBG_PRINT("HCIHandler::disconnect: address[%s, %s], handle %s, %s, ioError %d", + DBG_PRINT("HCIHandler::disconnect: address[%s, %s], handle %s, %s", peer_bdaddr.toString().c_str(), getBDAddressTypeString(peer_mac_type).c_str(), uint16HexString(conn_handle).c_str(), - conn->toString().c_str(), ioErrorCause); + conn->toString().c_str()); HCIStatusCode status; |