summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2022-09-14 15:41:12 +0200
committerSven Gothel <[email protected]>2022-09-14 15:41:12 +0200
commit511b6fc169544f72ab61b27bbe607979fee7ca97 (patch)
tree82e2c69f89c55b84a0b87105a08b0c8c418c7e23
parent04c6ea1c68a027072fb935d26f281ae924acf8a4 (diff)
jau::service_runner CB BTAdapter::l2capServer*(): Add 'noexcept'
-rw-r--r--api/direct_bt/BTAdapter.hpp6
-rw-r--r--api/direct_bt/L2CAPComm.hpp2
-rw-r--r--src/direct_bt/BTAdapter.cpp6
3 files changed, 7 insertions, 7 deletions
diff --git a/api/direct_bt/BTAdapter.hpp b/api/direct_bt/BTAdapter.hpp
index 810e1e41..9d6f0da4 100644
--- a/api/direct_bt/BTAdapter.hpp
+++ b/api/direct_bt/BTAdapter.hpp
@@ -511,9 +511,9 @@ namespace direct_bt {
std::unique_ptr<L2CAPClient> l2cap_att;
std::mutex mtx_l2cap_att;
std::condition_variable cv_l2cap_att;
- void l2capServerWork(jau::service_runner& sr);
- void l2capServerInit(jau::service_runner& sr);
- void l2capServerEnd(jau::service_runner& sr);
+ void l2capServerWork(jau::service_runner& sr) noexcept;
+ void l2capServerInit(jau::service_runner& sr) noexcept;
+ void l2capServerEnd(jau::service_runner& sr) noexcept;
std::unique_ptr<L2CAPClient> get_l2cap_connection(std::shared_ptr<BTDevice> device);
bool mgmtEvNewSettingsMgmt(const MgmtEvent& e) noexcept;
diff --git a/api/direct_bt/L2CAPComm.hpp b/api/direct_bt/L2CAPComm.hpp
index f897fed4..830bbc0c 100644
--- a/api/direct_bt/L2CAPComm.hpp
+++ b/api/direct_bt/L2CAPComm.hpp
@@ -173,7 +173,7 @@ namespace direct_bt {
bool is_open() const noexcept { return is_open_; }
/** The external `is interrupted` callback is used until close(), thereafter it is removed. */
- void set_interrupted_query(get_boolean_callback_t is_interrupted_cb) { is_interrupted_extern = is_interrupted_cb; }
+ void set_interrupted_query(get_boolean_callback_t is_interrupted_cb) noexcept { is_interrupted_extern = is_interrupted_cb; }
/** Returns true if interrupted by internal or external cause, hence shall stop connecting and reading. */
bool interrupted() const noexcept { return interrupted_int() || interrupted_ext(); }
diff --git a/src/direct_bt/BTAdapter.cpp b/src/direct_bt/BTAdapter.cpp
index 831eb734..44e0cd11 100644
--- a/src/direct_bt/BTAdapter.cpp
+++ b/src/direct_bt/BTAdapter.cpp
@@ -1789,7 +1789,7 @@ bool BTAdapter::mgmtEvLocalNameChangedMgmt(const MgmtEvent& e) noexcept {
return true;
}
-void BTAdapter::l2capServerInit(jau::service_runner& sr0) {
+void BTAdapter::l2capServerInit(jau::service_runner& sr0) noexcept {
(void)sr0;
l2cap_att_srv.set_interrupted_query( jau::bindMemberFunc(&l2cap_service, &jau::service_runner::shall_stop2) );
@@ -1799,14 +1799,14 @@ void BTAdapter::l2capServerInit(jau::service_runner& sr0) {
}
}
-void BTAdapter::l2capServerEnd(jau::service_runner& sr) {
+void BTAdapter::l2capServerEnd(jau::service_runner& sr) noexcept {
(void)sr;
if( !l2cap_att_srv.close() ) {
ERR_PRINT("Adapter[%d]: L2CAP ATT close failed: %s", dev_id, l2cap_att_srv.toString().c_str());
}
}
-void BTAdapter::l2capServerWork(jau::service_runner& sr) {
+void BTAdapter::l2capServerWork(jau::service_runner& sr) noexcept {
(void)sr;
std::unique_ptr<L2CAPClient> l2cap_att_ = l2cap_att_srv.accept();
if( BTRole::Slave == getRole() && nullptr != l2cap_att_ ) {