aboutsummaryrefslogtreecommitdiffstats
path: root/src/direct_bt
diff options
context:
space:
mode:
authorSven Göthel <[email protected]>2024-05-20 21:08:03 +0200
committerSven Göthel <[email protected]>2024-05-20 21:08:03 +0200
commit751a95e73ccd4f976184e6b75c51828d29509d59 (patch)
tree7f2613a46c15f2ff67485d3c0eebb8120f334604 /src/direct_bt
parentb08752925ac82d0b8b156ed3e12212647c9b7bc6 (diff)
Misc NOLINT() reviews
Diffstat (limited to 'src/direct_bt')
-rw-r--r--src/direct_bt/BTTypes0.cpp3
-rw-r--r--src/direct_bt/HCIHandler.cpp4
2 files changed, 4 insertions, 3 deletions
diff --git a/src/direct_bt/BTTypes0.cpp b/src/direct_bt/BTTypes0.cpp
index 69ca3d00..f7ebaf38 100644
--- a/src/direct_bt/BTTypes0.cpp
+++ b/src/direct_bt/BTTypes0.cpp
@@ -24,6 +24,7 @@
*/
#include <cstring>
+#include <jau/basic_types.hpp>
#include <string>
#include <memory>
#include <cstdint>
@@ -192,7 +193,7 @@ std::string BDAddressAndType::toString() const noexcept {
// *************************************************
static inline const int8_t * const_uint8_to_const_int8_ptr(const uint8_t* p) noexcept {
- return static_cast<const int8_t *>( static_cast<void *>( const_cast<uint8_t*>( p ) ) );
+ return static_cast<const int8_t *>( static_cast<void *>( const_cast<uint8_t*>( p ) ) ); // NOLINT(bugprone-casting-through-void): Alignment OK - same as reinterpret_cast<T*>( p )
}
std::string direct_bt::to_string(const BTRole v) noexcept {
diff --git a/src/direct_bt/HCIHandler.cpp b/src/direct_bt/HCIHandler.cpp
index 64d9bac7..12bd34dc 100644
--- a/src/direct_bt/HCIHandler.cpp
+++ b/src/direct_bt/HCIHandler.cpp
@@ -1658,12 +1658,12 @@ HCIStatusCode HCIHandler::le_read_phy(const uint16_t conn_handle, const BDAddres
jau::to_hexstring(conn_handle).c_str(), jau::to_hexstring(conn_handle_rcvd).c_str(), toString().c_str());
return HCIStatusCode::INTERNAL_FAILURE;
}
- switch( ev_phy->tx_phys ) {
+ switch( ev_phy->tx_phys ) { // NOLINT(bugprone-switch-missing-default-case): Handled
case 0x01: resTx = LE_PHYs::LE_1M; break;
case 0x02: resTx = LE_PHYs::LE_2M; break;
case 0x03: resTx = LE_PHYs::LE_CODED; break;
}
- switch( ev_phy->rx_phys ) {
+ switch( ev_phy->rx_phys ) { // NOLINT(bugprone-switch-missing-default-case): Handled
case 0x01: resRx = LE_PHYs::LE_1M; break;
case 0x02: resRx = LE_PHYs::LE_2M; break;
case 0x03: resRx = LE_PHYs::LE_CODED; break;